diff --git a/.emacs.d/config.org b/.emacs.d/config.org index 7944774..3da714c 100644 --- a/.emacs.d/config.org +++ b/.emacs.d/config.org @@ -61,7 +61,6 @@ Nastavimo vire nalaganja paketov in pa vklopimo privzeto nalaganje ~use-package~ (add-to-list 'package-archives '("org" . "https://orgmode.org/elpa/") t) (add-to-list 'package-archives '("elpa" . "https://elpa.gnu.org/packages/") t) (package-initialize) - ;(require 'use-package) #+end_src Vklop merjenja časa nalaganja posameznih paketov. @@ -111,8 +110,7 @@ In pa ukaz za ponovno naložit konfiguracijo emacsa. "[" 'previous-buffer "]" 'next-buffer "r" 'ponovno-nalozi-config - "u" 'font-lock-update - ) + "u" 'font-lock-update) #+end_src ** Upravljanje z okni @@ -270,7 +268,7 @@ V evil mode lahko linke znotraj ORG dokumentov odpiramo kar z ~RET~. Evil v ~treemacs~ drevesu datotečnega sistema. #+begin_src emacs-lisp - ;(use-package treemacs-evil :after treemacs) + (use-package treemacs-evil :after treemacs) #+end_src * Emacs splošno @@ -355,7 +353,6 @@ Paket za dopolnjevanje, nadomestek ~ivy~. Nudi nekoliko lepšo iskušnjo priporo (use-package consult :config (general-define-key - ;(global-set-key (kbd "M-x") 'counsel-M-x) "C-s" 'consult-line "C-c j" 'consult-git-grep "C-c k" 'consult-ag @@ -364,31 +361,15 @@ Paket za dopolnjevanje, nadomestek ~ivy~. Nudi nekoliko lepšo iskušnjo priporo "RET" 'consult-bookmark "/" 'consult-ripgrep "b b" 'consult-buffer - "f r" 'consult-recent-file :wk "nedavno odprto") + "f r" 'consult-recent-file :wk "nedavno odprto")) #+end_src -~counsel-M-x~ poganjalnik ukazov doplnimo s paketom ~smex~ za prikazovanje nedavno uporabljenih ukazov pri vrhu. +~M-x~ poganjalnik ukazov dopolnimo s paketom ~smex~ za prikazovanje nedavno uporabljenih ukazov pri vrhu. #+begin_src emacs-lisp (use-package smex) #+end_src -Šum pri iskalnih rezultatih ripgrep-a zmanjšamo z ignoriranjem ~node_modules~ direktorija javascript odvisnih paketov. - -#+begin_src emacs-lisp - (defvar my-rg-excludes '("node_modules") - "List of directories to exclude from `counsel-rg' results.") - (define-advice counsel-rg - (:around (fn &optional in dir opts &rest args) my-glob) - "Exclude `my-rg-excludes' from `counsel-rg' results." - (let ((dir (or dir default-directory))) - (dolist (x my-rg-excludes) - (let ((glob (and (file-in-directory-p x dir) - (file-relative-name (expand-file-name "**" x) dir)))) - (when glob (setq opts (concat "-g !" glob (and opts " ") opts)))))) - (apply fn in dir opts args))) -#+end_src - ** Pomoč / introspekcija Paket ~helpful~ obarva strani za pomoč ter doda več kontekstualnih informacij in pa nekaj funkcij za lažje razumevanje kaj je kje, recimo ~helpful-at-point~, ~helpful-callable~, ~helpful-command~... @@ -423,10 +404,9 @@ Paziti pa moramo na verzije emacsa; zaznali smo težave pri mešanju emacs 30/29 :general (start/leader-keys "c" '(:ignore t :wk "crdt") - "c c" 'crdt-connect - ; "c c" 'crdt-connect) - ;:general-config - ;(start/leader-keys + "c c" 'crdt-connect) + :general-config + (start/leader-keys "c" '(:ignore t :wk "crdt") "c u" 'crdt-list-users "c s" 'crdt-share-buffer @@ -492,9 +472,9 @@ Nekoliko bolj prijazen elisp REPL, ki ima med drugim zgodovino. ";" 'ielm) :config (advice-add 'ielm-send-input :after 'g-ielm-write-history) - (general-define-key - :keymaps 'inferior-emacs-list-mode-map - "C-l" 'comint-clear-buffer) + (general-define-key + :keymaps 'inferior-emacs-list-mode-map + "C-l" 'comint-clear-buffer)) #+end_src * ORG