Update .emacs.d/config.org
This commit is contained in:
parent
5314eba6c7
commit
7639493dee
1 changed files with 20 additions and 43 deletions
|
@ -1,11 +1,7 @@
|
||||||
#+auto_tangle:
|
#+auto_tangle:
|
||||||
|
|
||||||
* Emacs config
|
* Emacs config
|
||||||
|
|
||||||
** Packages initialization
|
** Packages initialization
|
||||||
|
|
||||||
Here, we're initializing MELPA, as well as package.el and use-package.
|
Here, we're initializing MELPA, as well as package.el and use-package.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(require 'package)
|
(require 'package)
|
||||||
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t)
|
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t)
|
||||||
|
@ -25,16 +21,13 @@ Here, we're initializing MELPA, as well as package.el and use-package.
|
||||||
|
|
||||||
** General config
|
** General config
|
||||||
*** no-littering
|
*** no-littering
|
||||||
|
no-littering is a useful package that allows to put all of the autosave files and temporary files in one directory (the files ending with ~ for instance).
|
||||||
no-littering is a useful package that allows to put all of the autosave files and temporary files in one directory (the files ending with ~ for instance)
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package no-littering)
|
(use-package no-littering)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Minimal interface
|
*** Minimal interface
|
||||||
|
|
||||||
We disable a lot of interface elements, to make the editor more minimal looking.
|
We disable a lot of interface elements, to make the editor more minimal looking.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(setq inhibit-startup-message t)
|
(setq inhibit-startup-message t)
|
||||||
(scroll-bar-mode -1)
|
(scroll-bar-mode -1)
|
||||||
|
@ -63,52 +56,48 @@ We disable a lot of interface elements, to make the editor more minimal looking.
|
||||||
(set-exec-path-from-shell-PATH)
|
(set-exec-path-from-shell-PATH)
|
||||||
|
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Bell
|
*** Bell
|
||||||
|
|
||||||
I don't like any visual or sound bell.
|
I don't like any visual or sound bell.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(setq ring-bell-function 'ignore)
|
(setq ring-bell-function 'ignore)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Font
|
*** Font
|
||||||
|
|
||||||
I use the default monospace font, as it allows me to configure it system wide and have everything coherent. We just make it bigger here for readability.
|
I use the default monospace font, as it allows me to configure it system wide and have everything coherent. We just make it bigger here for readability.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(set-face-attribute 'default nil :font "monospace" :height 125)
|
(set-face-attribute 'default nil :font "monospace" :height 125)
|
||||||
#+end_src
|
#+end_src
|
||||||
**** Ligatures
|
|
||||||
|
|
||||||
|
**** Ligatures
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package ligature
|
(use-package ligature
|
||||||
:config
|
:config
|
||||||
|
(ligature-set-ligatures 't '("www"))
|
||||||
(ligature-set-ligatures '(prog-mode tsx-ts-mode) '("--" "---" "==" "===" "!=" "!==" "=!="
|
(ligature-set-ligatures '(prog-mode tsx-ts-mode) '("--" "---" "==" "===" "!=" "!==" "=!="
|
||||||
"=:=" "=/=" "<=" ">=" "&&" "&&&" "&=" "++" "+++" "***" ";;" "!!"
|
"=:=" "=/=" "<=" ">=" "&&" "&&&" "&=" "++" "+++" "***" ";;" "!!"
|
||||||
"??" "???" "?:" "?." "?=" "<:" ":<" ":>" ">:" "<:<" "<>" "<<<" ">>>"
|
"??" "???" "?:" "?." "?=" "<:" ":<" ":>" ">:" "<:<" "<>" "<<<" ">>>"
|
||||||
"<<" ">>" "||" "-|" "_|_" "|-" "||-" "|=" "||=" "##" "###" "####"
|
"<<" ">>" "||" "-|" "_|_" "|-" "||-" "|=" "||=" "##" "###" "####"
|
||||||
"#{" "#[" "]#" "#(" "#?" "#_" "#_(" "#:" "#!" "#=" "^=" "<$>" "<$"
|
"#{" "#[" "]#" "#(" "#?" "#_" "#_(" "#:" "#!" "#=" "^=" "<$>" "<$"
|
||||||
"$>" "<+>" "<+" "+>" "<*>" "<*" "*>" "</" "</>" "/>" "<!--" "<#--"
|
"$>" "<+>" "<+" "+>" "<*>" "<*" "*>" "</" "</>" "/>" "<!--" "<#--"
|
||||||
"-->" "->" "->>" "<<-" "<-" "<=<" "=<<" "<<=" "<==" "<=>" "<==>"
|
"-->" "->" "->>" "<<-" "<-" "<=<" "=<<" "<<=" "<==" "<=>" "<==>"
|
||||||
"==>" "=>" "=>>" ">=>" ">>=" ">>-" ">-" "-<" "-<<" ">->" "<-<" "<-|"
|
"==>" "=>" "=>>" ">=>" ">>=" ">>-" ">-" "-<" "-<<" ">->" "<-<" "<-|"
|
||||||
"<=|" "|=>" "|->" "<->" "<~~" "<~" "<~>" "~~" "~~>" "~>" "~-" "-~"
|
"<=|" "|=>" "|->" "<->" "<~~" "<~" "<~>" "~~" "~~>" "~>" "~-" "-~"
|
||||||
"~@" "[||]" "|]" "[|" "|}" "{|" "[<" ">]" "|>" "<|" "||>" "<||"
|
"~@" "[||]" "|]" "[|" "|}" "{|" "[<" ">]" "|>" "<|" "||>" "<||"
|
||||||
"|||>" "<|||" "<|>" "..." ".." ".=" "..<" ".?" "::" ":::" ":=" "::="
|
"|||>" "<|||" "<|>" "..." ".." ".=" "..<" ".?" "::" ":::" ":=" "::="
|
||||||
":?" ":?>" "//" "///" "/*" "*/" "/=" "//=" "/==" "@_" "__" "???"
|
":?" ":?>" "//" "///" "/*" "*/" "/=" "//=" "/==" "@_" "__" "???"
|
||||||
"<:<" ";;;"))
|
"<:<" ";;;"))
|
||||||
(global-ligature-mode t))
|
(global-ligature-mode t))
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Visual mode
|
*** Visual mode
|
||||||
|
|
||||||
We turn on visual mode, so that lines can wrap nicely and do go beyond my Emacs buffer size.
|
We turn on visual mode, so that lines can wrap nicely and do go beyond my Emacs buffer size.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(visual-line-mode t)
|
(visual-line-mode t)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Theme
|
*** Theme
|
||||||
I use catppuccin as my theme, as I find it comfortable to work with (the Frappe flavor).
|
I use catppuccin as my theme, as I find it comfortable to work with (the Frappe flavor).
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package catppuccin-theme
|
(use-package catppuccin-theme
|
||||||
:init
|
:init
|
||||||
|
@ -118,9 +107,7 @@ I use catppuccin as my theme, as I find it comfortable to work with (the Frappe
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Modeline
|
*** Modeline
|
||||||
|
|
||||||
I use doom-modeline as my modeline, as I find it really clean and minimal.
|
I use doom-modeline as my modeline, as I find it really clean and minimal.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package doom-modeline
|
(use-package doom-modeline
|
||||||
:ensure t
|
:ensure t
|
||||||
|
@ -131,9 +118,7 @@ I use doom-modeline as my modeline, as I find it really clean and minimal.
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Completion
|
*** Completion
|
||||||
|
|
||||||
I use vertico as my completion framework. It's minimal, fast and tells me all I need to know and even sorts by history.
|
I use vertico as my completion framework. It's minimal, fast and tells me all I need to know and even sorts by history.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package vertico
|
(use-package vertico
|
||||||
:init
|
:init
|
||||||
|
@ -195,9 +180,7 @@ I use vertico as my completion framework. It's minimal, fast and tells me all I
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** which-key
|
*** which-key
|
||||||
|
|
||||||
which-key is a nice little package that allows to have a minibuffer showing which keybinds are available under prefixes.
|
which-key is a nice little package that allows to have a minibuffer showing which keybinds are available under prefixes.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package which-key
|
(use-package which-key
|
||||||
:config
|
:config
|
||||||
|
@ -205,9 +188,7 @@ which-key is a nice little package that allows to have a minibuffer showing whic
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** quelpa
|
*** quelpa
|
||||||
|
|
||||||
quelpa is a package that allows to build packages from source.
|
quelpa is a package that allows to build packages from source.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(unless (package-installed-p 'quelpa)
|
(unless (package-installed-p 'quelpa)
|
||||||
(with-temp-buffer
|
(with-temp-buffer
|
||||||
|
@ -226,7 +207,6 @@ use-package integration with quelpa.
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Reload org config config on save
|
*** Reload org config config on save
|
||||||
|
|
||||||
This allows to tangle automatically when saving the config. This is mostly for convenience.
|
This allows to tangle automatically when saving the config. This is mostly for convenience.
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package org-auto-tangle
|
(use-package org-auto-tangle
|
||||||
|
@ -240,11 +220,8 @@ This allows to tangle automatically when saving the config. This is mostly for c
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
** Org mode
|
** Org mode
|
||||||
|
|
||||||
*** Pretty bullets and headlines
|
*** Pretty bullets and headlines
|
||||||
|
|
||||||
I use org-superstar-mode, as it makes headlines and bullets look really nice.
|
I use org-superstar-mode, as it makes headlines and bullets look really nice.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package org-superstar
|
(use-package org-superstar
|
||||||
:hook (org-mode . org-superstar-mode))
|
:hook (org-mode . org-superstar-mode))
|
||||||
|
@ -278,6 +255,7 @@ I use org-superstar-mode, as it makes headlines and bullets look really nice.
|
||||||
:bind
|
:bind
|
||||||
("C-c p" . 'projectile-command-map))
|
("C-c p" . 'projectile-command-map))
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Autocompletion
|
*** Autocompletion
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package company
|
(use-package company
|
||||||
|
@ -294,14 +272,14 @@ I use org-superstar-mode, as it makes headlines and bullets look really nice.
|
||||||
:bind (:map yas-minor-mode-map
|
:bind (:map yas-minor-mode-map
|
||||||
("C-c C-e" . yas-expand)))
|
("C-c C-e" . yas-expand)))
|
||||||
#+end_src
|
#+end_src
|
||||||
*** Magit
|
|
||||||
|
|
||||||
|
*** Magit
|
||||||
Magit is a git client in Emacs.
|
Magit is a git client in Emacs.
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package magit)
|
(use-package magit)
|
||||||
#+end_src
|
#+end_src
|
||||||
*** Languages
|
|
||||||
|
|
||||||
|
*** Languages
|
||||||
**** Rust
|
**** Rust
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package rust-mode
|
(use-package rust-mode
|
||||||
|
@ -359,7 +337,6 @@ Magit is a git client in Emacs.
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
**** expand-region
|
**** expand-region
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(use-package expand-region
|
(use-package expand-region
|
||||||
:bind ("C-=" . er/expand-region))
|
:bind ("C-=" . er/expand-region))
|
||||||
|
|
Loading…
Reference in a new issue