Compare commits
4 Commits
985c228ce1
...
b115f6cd8c
Author | SHA1 | Date |
---|---|---|
Lucien Cartier-Tilet | b115f6cd8c | |
Lucien Cartier-Tilet | 3e841fa0b2 | |
Lucien Cartier-Tilet | c29b9a1131 | |
Lucien Cartier-Tilet | b876c6817e |
|
@ -1,8 +1,13 @@
|
||||||
|
# [[file:~/org/config/installation.org::*Execute bootstrap][Execute bootstrap:2]]
|
||||||
#!/usr/bin/fish
|
#!/usr/bin/fish
|
||||||
# -*- mode: fish -*-
|
# -*- mode: fish -*-
|
||||||
|
# Execute bootstrap:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Decrypt private yadm files][Decrypt private yadm files:1]]
|
||||||
yadm decrypt
|
yadm decrypt
|
||||||
|
# Decrypt private yadm files:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Get a correct keyboard layout][Get a correct keyboard layout:1]]
|
||||||
set keyboardconf \
|
set keyboardconf \
|
||||||
'Section "InputClass"
|
'Section "InputClass"
|
||||||
Identifier "system-keyboard"
|
Identifier "system-keyboard"
|
||||||
|
@ -12,19 +17,27 @@ set keyboardconf \
|
||||||
Option "XkbVariant" "bepo,,"
|
Option "XkbVariant" "bepo,,"
|
||||||
Option "XkbOptions" "grp:menu_toggle"
|
Option "XkbOptions" "grp:menu_toggle"
|
||||||
EndSection'
|
EndSection'
|
||||||
|
# Get a correct keyboard layout:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Get a correct keyboard layout][Get a correct keyboard layout:2]]
|
||||||
printf "\n# Set keyboard layout #########################################################\n\n"
|
printf "\n# Set keyboard layout #########################################################\n\n"
|
||||||
echo $keyboardconf | sudo tee /etc/X11/xorg.conf.d/00-keyboard.conf
|
echo $keyboardconf | sudo tee /etc/X11/xorg.conf.d/00-keyboard.conf
|
||||||
|
# Get a correct keyboard layout:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set our locale][Set our locale:1]]
|
||||||
set mylocales "en_US.UTF-8 UTF-8" "fr_FR.UTF-8 UTF-8" "ja_JP.UTF-8 UTF-8"
|
set mylocales "en_US.UTF-8 UTF-8" "fr_FR.UTF-8 UTF-8" "ja_JP.UTF-8 UTF-8"
|
||||||
|
# Set our locale:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set our locale][Set our locale:2]]
|
||||||
printf "\n# Set our locale ##############################################################\n\n"
|
printf "\n# Set our locale ##############################################################\n\n"
|
||||||
for item in $mylocales
|
for item in $mylocales
|
||||||
if test (grep -e "#$item" /etc/locale.gen)
|
if test (grep -e "#$item" /etc/locale.gen)
|
||||||
sudo sed -i "/$item/s/^#//g" /etc/locale.gen
|
sudo sed -i "/$item/s/^#//g" /etc/locale.gen
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
# Set our locale:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set our locale][Set our locale:3]]
|
||||||
set localeconf "LANG=en_US.UTF-8
|
set localeconf "LANG=en_US.UTF-8
|
||||||
LC_COLLATE=C
|
LC_COLLATE=C
|
||||||
LC_NAME=fr_FR.UTF-8
|
LC_NAME=fr_FR.UTF-8
|
||||||
|
@ -36,21 +49,33 @@ LC_PAPER=fr_FR.UTF-8
|
||||||
LC_ADDRESS=fr_FR.UTF-8
|
LC_ADDRESS=fr_FR.UTF-8
|
||||||
LC_TIME=fr_FR.UTF-8
|
LC_TIME=fr_FR.UTF-8
|
||||||
LC_MEASUREMENT=fr_FR.UTF-8"
|
LC_MEASUREMENT=fr_FR.UTF-8"
|
||||||
|
# Set our locale:3 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set our locale][Set our locale:4]]
|
||||||
echo $localeconf | sudo tee /etc/locale.conf
|
echo $localeconf | sudo tee /etc/locale.conf
|
||||||
|
# Set our locale:4 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set our locale][Set our locale:5]]
|
||||||
printf "\n# Generate locale #############################################################\n\n"
|
printf "\n# Generate locale #############################################################\n\n"
|
||||||
sudo locale-gen
|
sudo locale-gen
|
||||||
|
# Set our locale:5 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Create some folders][Create some folders:1]]
|
||||||
printf "\n# Create directories for mounting #############################################\n\n"
|
printf "\n# Create directories for mounting #############################################\n\n"
|
||||||
sudo mkdir -p /mnt/{USB,CD,Android}
|
sudo mkdir -p /mnt/{USB,CD,Android}
|
||||||
sudo chown $USER:(id -g $USER) /mnt/{USB,CD,Android}
|
sudo chown $USER:(id -g $USER) /mnt/{USB,CD,Android}
|
||||||
|
# Create some folders:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Create some folders][Create some folders:2]]
|
||||||
mkdir -p $HOME/.cache/nano/backups
|
mkdir -p $HOME/.cache/nano/backups
|
||||||
|
# Create some folders:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set user’s shell to fish][Set user’s shell to fish:1]]
|
||||||
printf "\n# Set fish as the default shell ###############################################\n\n"
|
printf "\n# Set fish as the default shell ###############################################\n\n"
|
||||||
chsh -s /usr/bin/fish
|
chsh -s /usr/bin/fish
|
||||||
|
# Set user’s shell to fish:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install =yay= if it isn’t already installed][Install =yay= if it isn’t already installed:1]]
|
||||||
if ! test (which yay)
|
if ! test (which yay)
|
||||||
printf "\n# Installing yay ##############################################################\n\n"
|
printf "\n# Installing yay ##############################################################\n\n"
|
||||||
cd
|
cd
|
||||||
|
@ -62,7 +87,9 @@ if ! test (which yay)
|
||||||
else
|
else
|
||||||
printf "\n# yay already installed #######################################################\n\n"
|
printf "\n# yay already installed #######################################################\n\n"
|
||||||
end
|
end
|
||||||
|
# Install =yay= if it isn’t already installed:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install basic packages][Install basic packages:1]]
|
||||||
set PACKAGES \
|
set PACKAGES \
|
||||||
acpilight adobe-source-han-sans-jp-fonts asar ascii aspell-en aspell-fr assimp \
|
acpilight adobe-source-han-sans-jp-fonts asar ascii aspell-en aspell-fr assimp \
|
||||||
awesome-terminal-fonts base-devel bat biber bleachbit bluez-firmware \
|
awesome-terminal-fonts base-devel bat biber bleachbit bluez-firmware \
|
||||||
|
@ -97,11 +124,15 @@ typescript-language-server-bin unicode unicode-emoji unrar usbutils valgrind \
|
||||||
vscode-css-languageserver-bin vscode-html-languageserver-bin w3m wget \
|
vscode-css-languageserver-bin vscode-html-languageserver-bin w3m wget \
|
||||||
x11-ssh-askpass xclip xdg-user-dirs-gtk xfsprogs xorg-apps xorg-drivers \
|
x11-ssh-askpass xclip xdg-user-dirs-gtk xfsprogs xorg-apps xorg-drivers \
|
||||||
xorg-server xorg-xinit xss-lock xvkbd yaml-language-server-bin yapf
|
xorg-server xorg-xinit xss-lock xvkbd yaml-language-server-bin yapf
|
||||||
|
# Install basic packages:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install basic packages][Install basic packages:2]]
|
||||||
printf "\n# Installing needed packages ##################################################\n\n"
|
printf "\n# Installing needed packages ##################################################\n\n"
|
||||||
sudo pacman -Syu
|
sudo pacman -Syu
|
||||||
yay -S --needed $PACKAGES
|
yay -S --needed $PACKAGES
|
||||||
|
# Install basic packages:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Tangle configuration files from Org files][Tangle configuration files from Org files:2]]
|
||||||
printf "\n# Tangling org files ##########################################################\n\n"
|
printf "\n# Tangling org files ##########################################################\n\n"
|
||||||
printf "\n\n==== Tangling bin.org\n\n"
|
printf "\n\n==== Tangling bin.org\n\n"
|
||||||
emacs -q --batch --eval "(require 'ob-tangle)" --eval "(org-babel-tangle-file \"~/org/config/bin.org\")"
|
emacs -q --batch --eval "(require 'ob-tangle)" --eval "(org-babel-tangle-file \"~/org/config/bin.org\")"
|
||||||
|
@ -119,101 +150,161 @@ printf "\n\n==== Tangling spacemacs.org\n\n"
|
||||||
emacs -q --batch --eval "(require 'ob-tangle)" --eval "(org-babel-tangle-file \"~/org/config/spacemacs.org\")"
|
emacs -q --batch --eval "(require 'ob-tangle)" --eval "(org-babel-tangle-file \"~/org/config/spacemacs.org\")"
|
||||||
printf "\n\n==== Tangling tmux.org\n\n"
|
printf "\n\n==== Tangling tmux.org\n\n"
|
||||||
emacs -q --batch --eval "(require 'ob-tangle)" --eval "(org-babel-tangle-file \"~/org/config/tmux.org\")"
|
emacs -q --batch --eval "(require 'ob-tangle)" --eval "(org-babel-tangle-file \"~/org/config/tmux.org\")"
|
||||||
|
# Tangle configuration files from Org files:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Tangle configuration files from Org files][Tangle configuration files from Org files:3]]
|
||||||
find ~/.local/bin -type f -exec chmod +x {} +
|
find ~/.local/bin -type f -exec chmod +x {} +
|
||||||
|
# Tangle configuration files from Org files:3 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Setting up Emacs: Installing Spacemacs][Setting up Emacs: Installing Spacemacs:1]]
|
||||||
printf "\n# Installing Spacemacs ########################################################\n\n"
|
printf "\n# Installing Spacemacs ########################################################\n\n"
|
||||||
rm -rf ~/.emacs.d
|
rm -rf ~/.config/emacs
|
||||||
|
# Setting up Emacs: Installing Spacemacs:1 ends here
|
||||||
|
|
||||||
git clone --single-branch --branch develop https://github.com/syl20bnr/spacemacs ~/.emacs.d
|
# [[file:~/org/config/installation.org::*Setting up Emacs: Installing Spacemacs][Setting up Emacs: Installing Spacemacs:2]]
|
||||||
|
git clone --single-branch --branch develop https://github.com/syl20bnr/spacemacs ~/.config/emacs
|
||||||
|
# Setting up Emacs: Installing Spacemacs:2 ends here
|
||||||
|
|
||||||
yadm checkout -- ~/.emacs.d/private/
|
# [[file:~/org/config/installation.org::*Setting up Emacs: Installing Spacemacs][Setting up Emacs: Installing Spacemacs:3]]
|
||||||
|
yadm checkout -- ~/.config/emacs/private/
|
||||||
|
# Setting up Emacs: Installing Spacemacs:3 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Update our dotfiles’ remotes][Update our dotfiles’ remotes:1]]
|
||||||
if ! test (echo "phundrak" | sed -e "s/^.*$USER//I")
|
if ! test (echo "phundrak" | sed -e "s/^.*$USER//I")
|
||||||
|
# Update our dotfiles’ remotes:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Update our dotfiles’ remotes][Update our dotfiles’ remotes:2]]
|
||||||
printf "\n# Update yadm’s remotes #######################################################\n\n"
|
printf "\n# Update yadm’s remotes #######################################################\n\n"
|
||||||
yadm remote set-url origin git@labs.phundrak.com:phundrak/dotfiles.git
|
yadm remote set-url origin git@labs.phundrak.com:phundrak/dotfiles.git
|
||||||
yadm remote add github git@github.com:phundrak/dotfiles.git
|
yadm remote add github git@github.com:phundrak/dotfiles.git
|
||||||
|
# Update our dotfiles’ remotes:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Update our dotfiles’ remotes][Update our dotfiles’ remotes:3]]
|
||||||
printf "\n# Decrypt encrypted dotfiles ##################################################\n\n"
|
printf "\n# Decrypt encrypted dotfiles ##################################################\n\n"
|
||||||
yadm decrypt
|
yadm decrypt
|
||||||
|
# Update our dotfiles’ remotes:3 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Update our dotfiles’ remotes][Update our dotfiles’ remotes:4]]
|
||||||
end
|
end
|
||||||
|
# Update our dotfiles’ remotes:4 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Get =envtpl=][Get =envtpl=:1]]
|
||||||
printf '\n# Install envtpl ##############################################################\n\n'
|
printf '\n# Install envtpl ##############################################################\n\n'
|
||||||
yay -Syu python-envtpl-git
|
yay -Syu python-envtpl-git
|
||||||
|
# Get =envtpl=:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Update our submodules][Update our submodules:1]]
|
||||||
printf "\n# Getting yadm susbmodules ####################################################\n\n"
|
printf "\n# Getting yadm susbmodules ####################################################\n\n"
|
||||||
yadm submodule update --init --recursive
|
yadm submodule update --init --recursive
|
||||||
|
# Update our submodules:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Generate our alt files][Generate our alt files:1]]
|
||||||
printf "\n# Generating alt files ########################################################\n\n"
|
printf "\n# Generating alt files ########################################################\n\n"
|
||||||
yadm alt
|
yadm alt
|
||||||
|
# Generate our alt files:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Installing Tryone’s Compton fork][Installing Tryone’s Compton fork:1]]
|
||||||
printf "\n# Installing tryone’s compton fork ############################################\n\n"
|
printf "\n# Installing tryone’s compton fork ############################################\n\n"
|
||||||
yay -S compton-tryone-git
|
yay -S compton-tryone-git
|
||||||
|
# Installing Tryone’s Compton fork:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Docker][Docker:1]]
|
||||||
printf "\n# Enabling and starting Docker ################################################\n\n"
|
printf "\n# Enabling and starting Docker ################################################\n\n"
|
||||||
sudo systemctl enable --now docker
|
sudo systemctl enable --now docker
|
||||||
|
# Docker:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Docker][Docker:2]]
|
||||||
read --prompt "echo 'Do you wish to be added to the `docker` group? (Y/n): ' " -l adddockergroup
|
read --prompt "echo 'Do you wish to be added to the `docker` group? (Y/n): ' " -l adddockergroup
|
||||||
if test $adddockergroup = 'y' || test $adddockergroup = "Y" || test $adddockergroup = ''
|
if test $adddockergroup = 'y' || test $adddockergroup = "Y" || test $adddockergroup = ''
|
||||||
sudo usermod -aG docker $USER
|
sudo usermod -aG docker $USER
|
||||||
end
|
end
|
||||||
|
# Docker:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Emacs][Emacs:1]]
|
||||||
printf "\n# Enabling Emacs as user service ##############################################\n\n"
|
printf "\n# Enabling Emacs as user service ##############################################\n\n"
|
||||||
systemctl --user enable --now emacs
|
systemctl --user enable --now emacs
|
||||||
|
# Emacs:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*SSH server][SSH server:1]]
|
||||||
read --prompt "echo 'Do you want to activate the ssh server? (Y/n): ' " -l sshdserver
|
read --prompt "echo 'Do you want to activate the ssh server? (Y/n): ' " -l sshdserver
|
||||||
if test $sshdserver = 'y' || test $sshdserver = "Y" || test $sshdserver = ''
|
if test $sshdserver = 'y' || test $sshdserver = "Y" || test $sshdserver = ''
|
||||||
printf "\n# Enabling ssh server #########################################################\n\n"
|
printf "\n# Enabling ssh server #########################################################\n\n"
|
||||||
sudo systemctl enable --now sshd
|
sudo systemctl enable --now sshd
|
||||||
end
|
end
|
||||||
|
# SSH server:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Ly][Ly:1]]
|
||||||
sudo systemctl enable --now ly
|
sudo systemctl enable --now ly
|
||||||
sudo systemctl disable getty@tty2
|
sudo systemctl disable getty@tty2
|
||||||
|
# Ly:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Acpilight][Acpilight:1]]
|
||||||
sudo usermod -aG video $USER
|
sudo usermod -aG video $USER
|
||||||
|
# Acpilight:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*NordVPN][NordVPN:1]]
|
||||||
sudo systemctl enable --now nordvpnd
|
sudo systemctl enable --now nordvpnd
|
||||||
|
# NordVPN:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Symlink some system config files][Symlink some system config files:1]]
|
||||||
for f in (find ~/.etc -type f)
|
for f in (find ~/.etc -type f)
|
||||||
set dest (echo $f | sed -n 's/^.*etc\(.*\)$/\/etc\1/p')
|
set dest (echo $f | sed -n 's/^.*etc\(.*\)$/\/etc\1/p')
|
||||||
sudo ln -s $f $dest
|
sudo ln -s $f $dest
|
||||||
end
|
end
|
||||||
|
# Symlink some system config files:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Symlink some system config files][Symlink some system config files:2]]
|
||||||
read --prompt "echo 'Symlink .nanorc to root’s .nanorc? (Y/n): ' " -l nanoroot
|
read --prompt "echo 'Symlink .nanorc to root’s .nanorc? (Y/n): ' " -l nanoroot
|
||||||
if test $nanoroot = 'y' || test $nanoroot = "Y" || test $nanoroot = ''
|
if test $nanoroot = 'y' || test $nanoroot = "Y" || test $nanoroot = ''
|
||||||
printf "\n# Symlinking .nanorc to root’s .nanorc ########################################\n\n"
|
printf "\n# Symlinking .nanorc to root’s .nanorc ########################################\n\n"
|
||||||
sudo ln -s $HOME/.nanorc /root/.nanorc
|
sudo ln -s $HOME/.nanorc /root/.nanorc
|
||||||
end
|
end
|
||||||
|
# Symlink some system config files:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Polybar Battery][Polybar Battery:1]]
|
||||||
printf "\n# Install polybar-battery #####################################################\n\n"
|
printf "\n# Install polybar-battery #####################################################\n\n"
|
||||||
cd ~/fromGIT
|
cd ~/fromGIT
|
||||||
git clone https://github.com/drdeimos/polybar_another_battery.git
|
git clone https://github.com/drdeimos/polybar_another_battery.git
|
||||||
cd polybar_another_battery
|
cd polybar_another_battery
|
||||||
go get -u github.com/distatus/battery/cmd/battery
|
go get -u github.com/distatus/battery/cmd/battery
|
||||||
make build
|
make build
|
||||||
|
# Polybar Battery:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Polybar Battery][Polybar Battery:2]]
|
||||||
ln -s polybar-ab ~/.local/bin/polybar-ab
|
ln -s polybar-ab ~/.local/bin/polybar-ab
|
||||||
|
# Polybar Battery:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Reveal.JS][Reveal.JS:1]]
|
||||||
printf "\n# Install Reveal.JS ###########################################################\n\n"
|
printf "\n# Install Reveal.JS ###########################################################\n\n"
|
||||||
cd ~/fromGIT
|
cd ~/fromGIT
|
||||||
git clone https://github.com/hakimel/reveal.js.git
|
git clone https://github.com/hakimel/reveal.js.git
|
||||||
|
# Reveal.JS:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install the toolchains][Install the toolchains:1]]
|
||||||
printf "\n# Install the rust toolchains, nightly is the default one #####################\n\n"
|
printf "\n# Install the rust toolchains, nightly is the default one #####################\n\n"
|
||||||
rustup default nightly
|
rustup default nightly
|
||||||
|
# Install the toolchains:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install the toolchains][Install the toolchains:2]]
|
||||||
rustup toolchain install stable
|
rustup toolchain install stable
|
||||||
|
# Install the toolchains:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install some utilities][Install some utilities:1]]
|
||||||
printf "\n# Add rust utilities ##########################################################\n\n"
|
printf "\n# Add rust utilities ##########################################################\n\n"
|
||||||
cargo install rustfmt racer
|
cargo install rustfmt racer
|
||||||
|
# Install some utilities:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install some utilities][Install some utilities:2]]
|
||||||
rustup component add src
|
rustup component add src
|
||||||
rustup component add rls
|
rustup component add rls
|
||||||
|
# Install some utilities:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install some python packages][Install some python packages:1]]
|
||||||
printf "\n# Installing Python packages ##################################################\n\n"
|
printf "\n# Installing Python packages ##################################################\n\n"
|
||||||
pip install --user pyls-isort pyls-mypy
|
pip install --user pyls-isort pyls-mypy
|
||||||
|
# Install some python packages:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install go packages][Install go packages:1]]
|
||||||
printf "\n# Installing Go packages ######################################################\n\n"
|
printf "\n# Installing Go packages ######################################################\n\n"
|
||||||
go get -v golang.org/x/tools/gopls@latest
|
go get -v golang.org/x/tools/gopls@latest
|
||||||
go get -u -v golang.org/x/tools/cmd/godoc
|
go get -u -v golang.org/x/tools/cmd/godoc
|
||||||
|
@ -231,19 +322,29 @@ go get -u -v github.com/mdempsky/gocode
|
||||||
go get -u -v github.com/rogpeppe/godef
|
go get -u -v github.com/rogpeppe/godef
|
||||||
go get -u -v github.com/zmb3/gogetdoc
|
go get -u -v github.com/zmb3/gogetdoc
|
||||||
go get -u -v golang.org/x/tools/gopls
|
go get -u -v golang.org/x/tools/gopls
|
||||||
|
# Install go packages:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set up Chicken (Scheme interpreter/compiler)][Set up Chicken (Scheme interpreter/compiler):1]]
|
||||||
printf "\n# Setting up Chicken ##########################################################\n\n"
|
printf "\n# Setting up Chicken ##########################################################\n\n"
|
||||||
chicken-install -s apropos chicken-doc
|
chicken-install -s apropos chicken-doc
|
||||||
|
# Set up Chicken (Scheme interpreter/compiler):1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Set up Chicken (Scheme interpreter/compiler)][Set up Chicken (Scheme interpreter/compiler):2]]
|
||||||
cd (chicken-csi -b -e "(import (chicken platform))" -p "(chicken-home)")
|
cd (chicken-csi -b -e "(import (chicken platform))" -p "(chicken-home)")
|
||||||
curl https://3e8.org/pub/chicken-doc/chicken-doc-repo.tgz | sudo tar zx
|
curl https://3e8.org/pub/chicken-doc/chicken-doc-repo.tgz | sudo tar zx
|
||||||
|
# Set up Chicken (Scheme interpreter/compiler):2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Clean the =pacman= and =yay= cache][Clean the =pacman= and =yay= cache:1]]
|
||||||
printf "\n# Clean the pacman and yay cache ##############################################\n\n"
|
printf "\n# Clean the pacman and yay cache ##############################################\n\n"
|
||||||
yay -Sc --noconfirm
|
yay -Sc --noconfirm
|
||||||
|
# Clean the =pacman= and =yay= cache:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install =fisher=][Install =fisher=:1]]
|
||||||
printf "\n# Installing fisher ###########################################################\n\n"
|
printf "\n# Installing fisher ###########################################################\n\n"
|
||||||
curl https://git.io/fisher --create-dirs -sLo ~/.config/fish/functions/fisher.fish
|
curl https://git.io/fisher --create-dirs -sLo ~/.config/fish/functions/fisher.fish
|
||||||
|
# Install =fisher=:1 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::*Install our extensions][Install our extensions:2]]
|
||||||
printf "\n# Installing Fisher Extensions ################################################\n\n"
|
printf "\n# Installing Fisher Extensions ################################################\n\n"
|
||||||
fisher add oh-my-fish/theme-bobthefish
|
fisher add oh-my-fish/theme-bobthefish
|
||||||
fisher add jorgebucaran/fish-bax
|
fisher add jorgebucaran/fish-bax
|
||||||
|
@ -254,7 +355,9 @@ fisher add jorgebucaran/fish-getopts
|
||||||
fisher add laughedelic/pisces
|
fisher add laughedelic/pisces
|
||||||
fisher add tuvistavie/fish-ssh-agent
|
fisher add tuvistavie/fish-ssh-agent
|
||||||
fisher add acomagu/fish-async-prompt
|
fisher add acomagu/fish-async-prompt
|
||||||
|
# Install our extensions:2 ends here
|
||||||
|
|
||||||
|
# [[file:~/org/config/installation.org::generate-tangle][generate-tangle]]
|
||||||
files=["bin.org", "fish.org", "i3.org", "index.org", "nano.org", "polybar.org", "spacemacs.org", "tmux.org"]
|
files=["bin.org", "fish.org", "i3.org", "index.org", "nano.org", "polybar.org", "spacemacs.org", "tmux.org"]
|
||||||
result = ''
|
result = ''
|
||||||
commandPrintf = 'printf "\\n\\n==== Tangling {0}\\n\\n"\n'
|
commandPrintf = 'printf "\\n\\n==== Tangling {0}\\n\\n"\n'
|
||||||
|
@ -262,3 +365,4 @@ commandEmacs = 'emacs -q --batch --eval "(require \'ob-tangle)" --eval "(org-bab
|
||||||
for file in files:
|
for file in files:
|
||||||
result += commandPrintf.format(file) + commandEmacs.format(file)
|
result += commandPrintf.format(file) + commandEmacs.format(file)
|
||||||
return result
|
return result
|
||||||
|
# generate-tangle ends here
|
||||||
|
|
|
@ -1,12 +0,0 @@
|
||||||
[Desktop Entry]
|
|
||||||
Name=Gnus (Emacs)
|
|
||||||
GenericName=Mail Client
|
|
||||||
Comment=Gnus' X handler
|
|
||||||
MimeType=x-scheme-handler/mailto;
|
|
||||||
Exec=emacsmail %F
|
|
||||||
Icon=emacs
|
|
||||||
Type=Application
|
|
||||||
Terminal=false
|
|
||||||
Categories=Network;Email;TextEditor;
|
|
||||||
StartupWMClass=Emacs
|
|
||||||
Keywords=Text;Editor;Email;Client;Gnus;
|
|
34
.spacemacs
34
.spacemacs
|
@ -4,31 +4,31 @@
|
||||||
This function is called at the very beginning of Spacemacs startup,
|
This function is called at the very beginning of Spacemacs startup,
|
||||||
before layer configuration.
|
before layer configuration.
|
||||||
It should only modify the values of Spacemacs settings."
|
It should only modify the values of Spacemacs settings."
|
||||||
(setq phundrak/src-dir (concat (getenv "HOME") "/.emacs.d/private/")
|
(setq phundrak//dotspacemacs-src-dir (concat (getenv "HOME") "/.config/emacs/private/")
|
||||||
phundrak/gnus-uc (concat (getenv "HOME") "/.gnus.el")
|
phundrak//dotspacemacs-gc (concat (getenv "HOME") "/.gnus.el")
|
||||||
phundrak/src (concat (getenv "HOME") "/org/config/spacemacs.org")
|
phundrak//dotspacemacs-src (concat (getenv "HOME") "/org/config/spacemacs.org")
|
||||||
phundrak/si (concat phundrak/src-dir "spacemacs-init.el")
|
phundrak//dotspacemacs-si (concat phundrak//dotspacemacs-src-dir "spacemacs-init.el")
|
||||||
phundrak/sl (concat phundrak/src-dir "spacemacs-layers.el")
|
phundrak//dotspacemacs-sl (concat phundrak//dotspacemacs-src-dir "spacemacs-layers.el")
|
||||||
phundrak/uc (concat phundrak/src-dir "user-config.el")
|
phundrak//dotspacemacs-uc (concat phundrak//dotspacemacs-src-dir "user-config.el")
|
||||||
phundrak/ui (concat phundrak/src-dir "user-init.el"))
|
phundrak//dotspacemacs-ui (concat phundrak//dotspacemacs-src-dir "user-init.el"))
|
||||||
(when (or (file-newer-than-file-p phundrak/src phundrak/si)
|
(when (or (file-newer-than-file-p phundrak//dotspacemacs-src phundrak//dotspacemacs-si)
|
||||||
(file-newer-than-file-p phundrak/src phundrak/sl)
|
(file-newer-than-file-p phundrak//dotspacemacs-src phundrak//dotspacemacs-sl)
|
||||||
(file-newer-than-file-p phundrak/src phundrak/ui)
|
(file-newer-than-file-p phundrak//dotspacemacs-src phundrak//dotspacemacs-ui)
|
||||||
(file-newer-than-file-p phundrak/src phundrak/uc)
|
(file-newer-than-file-p phundrak//dotspacemacs-src phundrak//dotspacemacs-uc)
|
||||||
(file-newer-than-file-p phundrak/src phundrak/gnus-uc))
|
(file-newer-than-file-p phundrak//dotspacemacs-src phundrak//dotspacemacs-gc))
|
||||||
(princ "Exporting new Emacs configuration from spacemacs.org through org-babel...")
|
(princ "Exporting new Emacs configuration from spacemacs.org through org-babel...")
|
||||||
(call-process
|
(call-process
|
||||||
(concat invocation-directory invocation-name)
|
(concat invocation-directory invocation-name)
|
||||||
nil nil t
|
nil nil t
|
||||||
"-q" "--batch" "--eval" "(require 'ob-tangle)"
|
"-q" "--batch" "--eval" "(require 'ob-tangle)"
|
||||||
"--eval" (format "(org-babel-tangle-file \"%s\")" phundrak/src))
|
"--eval" (format "(org-babel-tangle-file \"%s\")" phundrak//dotspacemacs-src))
|
||||||
(princ "done"))
|
(princ "done"))
|
||||||
(load-file phundrak/si))
|
(load-file phundrak//dotspacemacs-si))
|
||||||
|
|
||||||
(defun dotspacemacs/layers ()
|
(defun dotspacemacs/layers ()
|
||||||
"Layer configuration:
|
"Layer configuration:
|
||||||
This function should only modify configuration layer settings."
|
This function should only modify configuration layer settings."
|
||||||
(load-file phundrak/sl))
|
(load-file phundrak//dotspacemacs-sl))
|
||||||
|
|
||||||
(defun dotspacemacs/user-env ()
|
(defun dotspacemacs/user-env ()
|
||||||
"Environment variables setup.
|
"Environment variables setup.
|
||||||
|
@ -44,7 +44,7 @@ This function is called immediately after `dotspacemacs/init', before layer
|
||||||
configuration.
|
configuration.
|
||||||
It is mostly for variables that should be set before packages are loaded.
|
It is mostly for variables that should be set before packages are loaded.
|
||||||
If you are unsure, try setting them in `dotspacemacs/user-config' first."
|
If you are unsure, try setting them in `dotspacemacs/user-config' first."
|
||||||
(load-file phundrak/ui))
|
(load-file phundrak//dotspacemacs-ui))
|
||||||
|
|
||||||
(defun dotspacemacs/user-load ()
|
(defun dotspacemacs/user-load ()
|
||||||
"Library to load while dumping.
|
"Library to load while dumping.
|
||||||
|
@ -59,7 +59,7 @@ This function is called at the very end of Spacemacs startup, after layer
|
||||||
configuration.
|
configuration.
|
||||||
Put your configuration code here, except for variables that should be set
|
Put your configuration code here, except for variables that should be set
|
||||||
before packages are loaded."
|
before packages are loaded."
|
||||||
(load-file phundrak/uc))
|
(load-file phundrak//dotspacemacs-uc))
|
||||||
|
|
||||||
|
|
||||||
;; Do not write anything past this comment. This is where Emacs will
|
;; Do not write anything past this comment. This is where Emacs will
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
#+HTML_HEAD_EXTRA: <meta name="description" content="Phundrak-flavored Arch Linux" />
|
#+HTML_HEAD_EXTRA: <meta name="description" content="Phundrak-flavored Arch Linux" />
|
||||||
#+HTML_HEAD_EXTRA: <meta property="og:title" content="Phundrak-flavored Arch Linux" />
|
#+HTML_HEAD_EXTRA: <meta property="og:title" content="Phundrak-flavored Arch Linux" />
|
||||||
#+HTML_HEAD_EXTRA: <meta property="og:description" content="How to install a Phundrak-flavored Arch Linux" />
|
#+HTML_HEAD_EXTRA: <meta property="og:description" content="How to install a Phundrak-flavored Arch Linux" />
|
||||||
#+PROPERTY: header-args :exports code
|
#+PROPERTY: header-args :exports code :comments link
|
||||||
|
|
||||||
* Table of Contents :TOC_4_gh:noexport:
|
* Table of Contents :TOC_4_gh:noexport:
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
|
@ -133,7 +133,7 @@
|
||||||
* Execute bootstrap
|
* Execute bootstrap
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
:CUSTOM_ID: h-c13d132f-9e69-4bb0-838b-29c7c5611f11
|
:CUSTOM_ID: h-c13d132f-9e69-4bb0-838b-29c7c5611f11
|
||||||
:HEADER-ARGS: :tangle ~/.config/yadm/bootstrap
|
:HEADER-ARGS: :tangle ~/.config/yadm/bootstrap :comments link
|
||||||
:END:
|
:END:
|
||||||
=yadm= comes with a very handy feature: its bootstrap script. We can execute
|
=yadm= comes with a very handy feature: its bootstrap script. We can execute
|
||||||
it by running the following command:
|
it by running the following command:
|
||||||
|
@ -389,23 +389,24 @@
|
||||||
:CUSTOM_ID: h-bd5a92c4-1a4f-49ea-a447-050a4ff0301c
|
:CUSTOM_ID: h-bd5a92c4-1a4f-49ea-a447-050a4ff0301c
|
||||||
:END:
|
:END:
|
||||||
Now, the first thing we want to do with Emacs is install its Spacemacs
|
Now, the first thing we want to do with Emacs is install its Spacemacs
|
||||||
distribution. We’ll clone its =develop= branch into =~/.emacs.d=. We need to
|
distribution. We’ll clone its =develop= branch into =~/.config/emacs=. We
|
||||||
do this prior to our dotfiles’ cloning because of some submodules that are
|
need to do this prior to our dotfiles’ cloning because of some submodules
|
||||||
cloned within our =~/.emacs.d= directory, and git won’t let us clone
|
that are cloned within our =~/.config/emacs= directory, and git won’t let us
|
||||||
Spacemacs in an already existing and non-empty directory. To make sure it
|
clone Spacemacs in an already existing and non-empty directory. To make sure
|
||||||
isn’t one, let’s delete any potentially existing =~/.emacs.d= directory:
|
it isn’t one, let’s delete any potentially existing =~/.config/emacs=
|
||||||
|
directory:
|
||||||
#+BEGIN_SRC fish
|
#+BEGIN_SRC fish
|
||||||
printf "\n# Installing Spacemacs ########################################################\n\n"
|
printf "\n# Installing Spacemacs ########################################################\n\n"
|
||||||
rm -rf ~/.emacs.d
|
rm -rf ~/.config/emacs
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
Now we can clone Spacemacs:
|
Now we can clone Spacemacs:
|
||||||
#+BEGIN_SRC fish
|
#+BEGIN_SRC fish
|
||||||
git clone --single-branch --branch develop https://github.com/syl20bnr/spacemacs ~/.emacs.d
|
git clone --single-branch --branch develop https://github.com/syl20bnr/spacemacs ~/.config/emacs
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
And we can restore what might have been deleted in our =~/.emacs.d/private=
|
And we can restore what might have been deleted in our =~/.emacs.d/private=
|
||||||
directory:
|
directory:
|
||||||
#+BEGIN_SRC fish
|
#+BEGIN_SRC fish
|
||||||
yadm checkout -- ~/.emacs.d/private/
|
yadm checkout -- ~/.config/emacs/private/
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
** Set up dotfiles
|
** Set up dotfiles
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
#+HTML_HEAD_EXTRA: <meta name="description" content="Phundrak's nano configuration" />
|
#+HTML_HEAD_EXTRA: <meta name="description" content="Phundrak's nano configuration" />
|
||||||
#+HTML_HEAD_EXTRA: <meta property="og:title" content="Phundrak's nano configuration" />
|
#+HTML_HEAD_EXTRA: <meta property="og:title" content="Phundrak's nano configuration" />
|
||||||
#+HTML_HEAD_EXTRA: <meta property="og:description" content="Description of the nano configuration of Phundrak" />
|
#+HTML_HEAD_EXTRA: <meta property="og:description" content="Description of the nano configuration of Phundrak" />
|
||||||
#+PROPERTY: header-args :tangle ~/.nanorc
|
#+PROPERTY: header-args :tangle ~/.config/nano/nanorc
|
||||||
|
|
||||||
* Table of Contents :TOC_4_gh:noexport:
|
* Table of Contents :TOC_4_gh:noexport:
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
|
@ -147,5 +147,5 @@
|
||||||
them at the same time. Since the submodule is cloned in =~/.config/nanorc=,
|
them at the same time. Since the submodule is cloned in =~/.config/nanorc=,
|
||||||
we can add only one line to include all of the =.nanorc= files.
|
we can add only one line to include all of the =.nanorc= files.
|
||||||
#+BEGIN_SRC conf
|
#+BEGIN_SRC conf
|
||||||
include ~/.config/nanorc/*.nanorc
|
include ~/.config/nano/nano-syntax/*.nanorc
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
|
@ -135,7 +135,7 @@
|
||||||
|
|
||||||
* Spacemacs layers and packages
|
* Spacemacs layers and packages
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
:header-args:emacs-lisp: :comments link :tangle ~/.emacs.d/private/spacemacs-layers.el :exports code
|
:header-args:emacs-lisp: :comments link :tangle ~/.config/emacs/private/spacemacs-layers.el :exports code
|
||||||
:CUSTOM_ID: h-9d9869e0-4672-419c-bf37-3d3ae1b7c0aa
|
:CUSTOM_ID: h-9d9869e0-4672-419c-bf37-3d3ae1b7c0aa
|
||||||
:END:
|
:END:
|
||||||
Here will be our layer configuration set. Everything here is set with a
|
Here will be our layer configuration set. Everything here is set with a
|
||||||
|
@ -646,7 +646,7 @@
|
||||||
* Init
|
* Init
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
:CUSTOM_ID: h-3f3c8a0b-56cd-4be6-b019-3ba6f1e24f96
|
:CUSTOM_ID: h-3f3c8a0b-56cd-4be6-b019-3ba6f1e24f96
|
||||||
:header-args:emacs-lisp: :comments link :tangle ~/.emacs.d/private/spacemacs-init.el :exports code
|
:header-args:emacs-lisp: :comments link :tangle ~/.config/emacs/private/spacemacs-init.el :exports code
|
||||||
:END:
|
:END:
|
||||||
The ~dotspacemacs/init~ function is the one called at the very begining of the
|
The ~dotspacemacs/init~ function is the one called at the very begining of the
|
||||||
Spacemacs startup, before any kind of configuration, including the layer
|
Spacemacs startup, before any kind of configuration, including the layer
|
||||||
|
@ -687,7 +687,7 @@
|
||||||
should be added when invoking Emacs 27.1 executable from the command line,
|
should be added when invoking Emacs 27.1 executable from the command line,
|
||||||
for instance:
|
for instance:
|
||||||
#+BEGIN_SRC sh :tangle no :exports code
|
#+BEGIN_SRC sh :tangle no :exports code
|
||||||
./emacs --dump-file=~/.emacs.d/.cache/dumps/spacemacs.pdmp
|
./emacs --dump-file=~/.config/emacs/.cache/dumps/spacemacs.pdmp
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
The default value of this variable is ="spacemacs.pdmp"=.
|
The default value of this variable is ="spacemacs.pdmp"=.
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
@ -1202,7 +1202,7 @@
|
||||||
|
|
||||||
You can also set a custom emacs server socket location. If the value is
|
You can also set a custom emacs server socket location. If the value is
|
||||||
~nil~, Emacs will use whatever the Emacs default is, otherwise a directory
|
~nil~, Emacs will use whatever the Emacs default is, otherwise a directory
|
||||||
path like ="~/.emacs.d/server"=. It has no effect if
|
path like ="~/.config/emacs/server"=. It has no effect if
|
||||||
~dotspacemacs-enable-server~ is ~nil~.
|
~dotspacemacs-enable-server~ is ~nil~.
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(setq-default dotspacemacs-server-socket-dir nil)
|
(setq-default dotspacemacs-server-socket-dir nil)
|
||||||
|
@ -1263,13 +1263,13 @@
|
||||||
* User Initialization
|
* User Initialization
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
:CUSTOM_ID: h-e297b9be-9b0d-4c2d-bb6e-402f0d00be0d
|
:CUSTOM_ID: h-e297b9be-9b0d-4c2d-bb6e-402f0d00be0d
|
||||||
:header-args:emacs-lisp: :comments link :tangle ~/.emacs.d/private/user-init.el :exports code
|
:header-args:emacs-lisp: :comments link :tangle ~/.config/emacs/private/user-init.el :exports code
|
||||||
:END:
|
:END:
|
||||||
While Emacs and especially Spacemacs loads, I want it to initialize some
|
While Emacs and especially Spacemacs loads, I want it to initialize some
|
||||||
elements and load some packages. First of all, I want it to load my private
|
elements and load some packages. First of all, I want it to load my private
|
||||||
Emacs config file:
|
Emacs config file:
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(load "~/.emacs.d/private/private_emacs.el")
|
(load "~/.config/emacs/private/private_emacs.el")
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
Then, I want a couple of requires:
|
Then, I want a couple of requires:
|
||||||
|
@ -1308,7 +1308,7 @@
|
||||||
* User Configuration
|
* User Configuration
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
:CUSTOM_ID: h-7a36d3a0-8bb6-4d9d-9402-eadbc49fef32
|
:CUSTOM_ID: h-7a36d3a0-8bb6-4d9d-9402-eadbc49fef32
|
||||||
:header-args:emacs-lisp: :comments link :tangle ~/.emacs.d/private/user-config.el :exports code
|
:header-args:emacs-lisp: :comments link :tangle ~/.config/emacs/private/user-config.el :exports code
|
||||||
:END:
|
:END:
|
||||||
** ASM configuration
|
** ASM configuration
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
|
@ -2688,11 +2688,17 @@
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
:CUSTOM_ID: h-f193126f-abc1-4287-aa70-4f2080d2ef8f
|
:CUSTOM_ID: h-f193126f-abc1-4287-aa70-4f2080d2ef8f
|
||||||
:END:
|
:END:
|
||||||
As you will see, I defined A LOT of custom shortcuts. All of them are
|
As you will see, I defined a LOT of custom shortcuts. Most of them are
|
||||||
Spacemacs shortcuts, defined in a way they can be used seamlessly with Evil.
|
Spacemacs shortcuts, defined in a way they can be used seamlessly with Evil.
|
||||||
First of all, these shortcuts all begin with ~o~, which is a prefix reserved
|
Only two shortcuts are defined the vanilla way for Emacs:
|
||||||
for user-defined shortcuts so they won’t conflict with any package. Let’s
|
#+BEGIN_SRC emacs-lisp
|
||||||
declare it like so.
|
(global-set-key (kbd "M-»") 'end-of-buffer)
|
||||||
|
(global-set-key (kbd "M-«") 'beginning-of-buffer)
|
||||||
|
#+END_SRC
|
||||||
|
|
||||||
|
Spacemacs shortcuts all begin with ~o~, which is a prefix reserved for
|
||||||
|
user-defined shortcuts so they won’t conflict with any package. Let’s declare
|
||||||
|
it like so.
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(spacemacs/declare-prefix "o" "custom")
|
(spacemacs/declare-prefix "o" "custom")
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
@ -2704,16 +2710,16 @@
|
||||||
Before some more specialized categories, I have two commands which don’t fit
|
Before some more specialized categories, I have two commands which don’t fit
|
||||||
into any other category that I sometime use:
|
into any other category that I sometime use:
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(spacemacs/declare-prefix "oB" "byte-compile .emacs.d")
|
(spacemacs/declare-prefix "oB" "byte-compile ~/.config/emacs")
|
||||||
(spacemacs/declare-prefix "or" "external command")
|
(spacemacs/declare-prefix "or" "external command")
|
||||||
(spacemacs/set-leader-keys
|
(spacemacs/set-leader-keys
|
||||||
"oB" (lambda () (byte-recompile-directory (expand-file-name "~/.emacs.d") 0))
|
"oB" (lambda () (byte-recompile-directory (expand-file-name "~/.config/emacs") 0))
|
||||||
"or" 'helm-run-external-command)
|
"or" 'helm-run-external-command)
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
~oB~ byte-compiles every ~.el~ file located in the =~/.emacs.d/= directory —
|
~oB~ byte-compiles every ~.el~ file located in the =~/.config/emacs/=
|
||||||
it can be useful in case of package upgrade and an old ~.elc~ file still
|
directory — it can be useful in case of package upgrade and an old ~.elc~
|
||||||
loads instead of an uncompiled but newer ~.el~ file.
|
file still loads instead of an uncompiled but newer ~.el~ file.
|
||||||
|
|
||||||
~or~ on the other hand invokes an external comand the same way [[https://wiki.archlinux.org/index.php/Dmenu][dmenu]] would.
|
~or~ on the other hand invokes an external comand the same way [[https://wiki.archlinux.org/index.php/Dmenu][dmenu]] would.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue