From 38e8ea43cd8943f8f6d46ec98c3cf744472aee7c Mon Sep 17 00:00:00 2001 From: Thomas Dehaeze Date: Wed, 15 Apr 2026 13:35:39 +0200 Subject: [PATCH] Improvements when installing the new machine --- bash.org | 8 +++++--- doom.org | 21 +++++++-------------- install.org | 5 +---- scripts/install-desktop.sh | 5 +---- vim.org | 3 +-- 5 files changed, 15 insertions(+), 27 deletions(-) diff --git a/bash.org b/bash.org index 6735a42..fac1c1c 100644 --- a/bash.org +++ b/bash.org @@ -238,8 +238,10 @@ export TEXMFHOME=$HOME/.local/share/texmf *** Linkding #+begin_src bash -export LINKDING_URL=`pass nas/linkding_url` -export LINKDING_TOKEN=`pass nas/linkding_token` +if [ "$(hostnamectl hostname)" = "ldehaeze" ]; then + export LINKDING_URL=`pass nas/linkding_url` + export LINKDING_TOKEN=`pass nas/linkding_token` +fi #+end_src *** Restic @@ -258,7 +260,7 @@ export PATH ** Automatically run =startx= #+begin_src bash -if [ -z "${DISPLAY}" ] && [ "${XDG_VTNR}" -eq 1 ]; then +if [ -z "${DISPLAY}" ] && [ -n "${XDG_VTNR}" ] && [ "${XDG_VTNR}" -eq 1 ]; then exec startx fi #+end_src diff --git a/doom.org b/doom.org index fbd3a01..bc25b06 100644 --- a/doom.org +++ b/doom.org @@ -33,29 +33,22 @@ echo "==> Emacs packages" paru -S --needed emacs aspell aspell-en aspell-fr #+end_src -** Doom Emacs - -#+begin_src bash -echo "==> Installing Doom Emacs" -git clone --depth 1 https://github.com/doomemacs/doomemacs ~/.config/emacs -"${DOOM}" install --no-config -#+end_src - ** Tangle Configuration Tangle =doom.org= to generate =config.el=, =init.el= and =packages.el=: #+begin_src bash echo "==> Tangling doom.org" -emacsclient -e "(org-babel-tangle-file \"${DOTFILES}/doom.org\")" \ - || emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/doom.org\")" +mkdir ${HOME}/.config/doom +emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/doom.org\")" #+end_src -** Sync +** Doom Install #+begin_src bash -echo "==> Running doom sync" -"${DOOM}" sync +echo "==> Installing Doom Emacs" +git clone --depth 1 https://github.com/doomemacs/doomemacs ~/.config/emacs +"${DOOM}" install #+end_src * Introduction and Resources @@ -3210,7 +3203,7 @@ Provides nice functions such as: ;;nim ; python + lisp at the speed of c ;;nix ; I hereby declare "nix geht mehr!" ;;ocaml ; an objective camel - (org +pretty +roam2 +hugo +noter) ; organize your plain life in plain text + (org +pretty +roam +hugo +noter) ; organize your plain life in plain text ;;php ; perl's insecure younger brother ;;plantuml ; diagrams for confusing people more ;;graphviz ; diagrams for confusing yourself even more diff --git a/install.org b/install.org index 656b56b..8c45611 100644 --- a/install.org +++ b/install.org @@ -50,8 +50,7 @@ set -euo pipefail DOTFILES="${HOME}/.config/literate-dotfiles" tangle() { - emacsclient -e "(org-babel-tangle-file \"${DOTFILES}/$1\")" \ - || emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/$1\")" + emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/$1\")" } #+end_src @@ -69,10 +68,8 @@ paru -S --needed \ kitty \ bash bash-completion \ zoxide \ - nerd-fonts-hack noto-fonts-emoji \ xorg-xrandr arandr \ xautocfg \ - arc-gtk-theme xcursor-breeze \ feh xwallpaper #+end_src diff --git a/scripts/install-desktop.sh b/scripts/install-desktop.sh index 112fb50..366888c 100755 --- a/scripts/install-desktop.sh +++ b/scripts/install-desktop.sh @@ -4,8 +4,7 @@ set -euo pipefail DOTFILES="${HOME}/.config/literate-dotfiles" tangle() { - emacsclient -e "(org-babel-tangle-file \"${DOTFILES}/$1\")" \ - || emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/$1\")" + emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/$1\")" } echo "==> Desktop packages" @@ -19,10 +18,8 @@ paru -S --needed \ kitty \ bash bash-completion \ zoxide \ - nerd-fonts-hack noto-fonts-emoji \ xorg-xrandr arandr \ xautocfg \ - arc-gtk-theme xcursor-breeze \ feh xwallpaper echo "==> Tangling desktop configs" diff --git a/vim.org b/vim.org index fe08241..bf2cef9 100644 --- a/vim.org +++ b/vim.org @@ -36,8 +36,7 @@ Tangle =vim.org= to generate =~/.config/nvim/init.vim=: #+begin_src bash echo "==> Tangling vim.org" -emacsclient -e "(org-babel-tangle-file \"${DOTFILES}/vim.org\")" \ - || emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/vim.org\")" +emacs --batch -l org --eval "(org-babel-tangle-file \"${DOTFILES}/vim.org\")" #+end_src ** Install Plugins