feat: Switch to emacs as main editor
This commit is contained in:
parent
610698b3c3
commit
3b8ce96db1
15
.aliases
15
.aliases
@ -2,20 +2,29 @@ alias o="evince2"
|
|||||||
|
|
||||||
alias pro="cd ~/Documents/Projects"
|
alias pro="cd ~/Documents/Projects"
|
||||||
alias doc="cd ~/Documents"
|
alias doc="cd ~/Documents"
|
||||||
alias vim="nvim"
|
|
||||||
alias activenv="mamba activate hic2023py3.11"
|
alias activenv="mamba activate hic2023py3.11"
|
||||||
|
|
||||||
alias int="cd ~/Documents/cours/licence/L3/stage/pasteur/project/"
|
alias int="cd ~/Documents/cours/licence/L3/stage/pasteur/projects/"
|
||||||
|
alias blog="cd ~/Documents/Projects/myself/log/"
|
||||||
|
|
||||||
|
# Print field name from header with the field rank
|
||||||
|
csv_fields() {
|
||||||
|
local delimiter
|
||||||
|
delimiter="${2:-\t}"
|
||||||
|
local file
|
||||||
|
file="${1}"
|
||||||
|
head -n 1 "${file}" | tr "${delimiter}" "\n" | awk '{print NR, $0}'
|
||||||
|
}
|
||||||
|
|
||||||
export templates_dir="~/Documents/Projects/templates"
|
export templates_dir="~/Documents/Projects/templates"
|
||||||
alias new.td='copier "$templates_dir/latex/td.template"'
|
alias new.td='copier "$templates_dir/latex/td.template"'
|
||||||
alias new.cm='copier "$templates_dir/latex/cm.template"'
|
alias new.cm='copier "$templates_dir/latex/cm.template"'
|
||||||
alias new.letter='copier "$templates_dir/latex/letter.template"'
|
alias new.letter='copier "$templates_dir/latex/letter.template"'
|
||||||
alias taquin.sync="rsync -azvu '/home/sortion/Documents/cours/licence/L3/S6/intelligence artificielle/DM/DM2/taquin/' leon.talpa:/home/sortion/Documents/Projects/taquin/ && rsync -azvu leon.talpa:/home/sortion/Documents/Projects/taquin/ '/home/sortion/Documents/cours/licence/L3/S6/intelligence artificielle/DM/DM2/taquin/'"
|
|
||||||
|
|
||||||
pdfcompress () {
|
pdfcompress () {
|
||||||
gs -q -dNOPAUSE -dBATCH -dSAFER -sDEVICE=pdfwrite -dCompatibilityLevel=1.3 -dPDFSETTINGS=/screen -dEmbedAllFonts=true -dSubsetFonts=true -dColorImageDownsampleType=/Bicubic -dColorImageResolution=144 -dGrayImageDownsampleType=/Bicubic -dGrayImageResolution=144 -dMonoImageDownsampleType=/Bicubic -dMonoImageResolution=144 -sOutputFile="$2" "$1";
|
gs -q -dNOPAUSE -dBATCH -dSAFER -sDEVICE=pdfwrite -dCompatibilityLevel=1.3 -dPDFSETTINGS=/screen -dEmbedAllFonts=true -dSubsetFonts=true -dColorImageDownsampleType=/Bicubic -dColorImageResolution=144 -dGrayImageDownsampleType=/Bicubic -dGrayImageResolution=144 -dMonoImageDownsampleType=/Bicubic -dMonoImageResolution=144 -sOutputFile="$2" "$1";
|
||||||
}
|
}
|
||||||
|
|
||||||
colorinvert() { convert "$1" -channel RGB -negate "$(echo $1 | sed 's/\./-inv\./')"
|
colorinvert() { convert "$1" -channel RGB -negate "$(echo $1 | sed 's/\./-inv\./')"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
21
.loadenv.sh
21
.loadenv.sh
@ -1,8 +1,9 @@
|
|||||||
export LUA_PATH='/usr/share/lua/5.4/?.lua;/usr/share/lua/5.4/?/init.lua;/usr/lib64/lua/5.4/?.lua;/usr/lib64/lua/5.4/?/init.lua;./?.lua;./?/init.lua;/home/sortion/.luarocks/share/lua/5.4/?.lua;/home/sortion/.luarocks/share/lua/5.4/?/init.lua'
|
export PATH="/home/$USER/.luarocks/bin:/home/$USER/.julia/bin:/home/$USER/.cargo/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/home/$USER/.local/bin:/home/$USER/bin:/home/$USER/Documents/cours/tools/bin/:/usr/games/:/home/$USER/.config/emacs/bin/"
|
||||||
export LUA_CPATH='/usr/lib64/lua/5.4/?.so;/usr/lib64/lua/5.4/loadall.so;./?.so;/home/sortion/.luarocks/lib/lua/5.4/?.so;/usr/lib/lua/5.4/?.so'
|
|
||||||
export PATH='/home/sortion/.luarocks/bin:/home/sortion/.julia/bin:/home/sortion/.nvm/versions/node/v17.9.1/bin:/home/sortion/.cargo/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/opt/quarto-1.3.433/bin:/home/sortion/.local/bin:/home/sortion/bin:/home/sortion/.antigen/bundles/robbyrussell/oh-my-zsh/lib:/home/sortion/.antigen/bundles/zsh-users/zsh-syntax-highlighting:/home/sortion/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/git:/home/sortion/Documents/cours/tools/bin/:/usr/games/'
|
|
||||||
|
|
||||||
export EDITOR=vim
|
# export EDITOR=vim
|
||||||
|
export ALTERNATE_EDITOR=""
|
||||||
|
export EDITOR="emacsclient -t" # $EDITOR opens in terminal
|
||||||
|
export VISUAL="emacsclient -c -a emacs" # $VISUAL opens in GUI mode
|
||||||
|
|
||||||
# nvm
|
# nvm
|
||||||
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
|
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
|
||||||
@ -19,19 +20,19 @@ eval $(thefuck --alias)
|
|||||||
|
|
||||||
# >>> conda initialize >>>
|
# >>> conda initialize >>>
|
||||||
# !! Contents within this block are managed by 'conda init' !!
|
# !! Contents within this block are managed by 'conda init' !!
|
||||||
__conda_setup="$('/home/sortion/.local/share/mambaforge/bin/conda' 'shell.zsh' 'hook' 2>/dev/null)"
|
__conda_setup="$('/home/$USER/.local/share/mambaforge/bin/conda' 'shell.zsh' 'hook' 2>/dev/null)"
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
eval "$__conda_setup"
|
eval "$__conda_setup"
|
||||||
else
|
else
|
||||||
if [ -f "/home/sortion/.local/share/mambaforge/etc/profile.d/conda.sh" ]; then
|
if [ -f "/home/$USER/.local/share/mambaforge/etc/profile.d/conda.sh" ]; then
|
||||||
. "/home/sortion/.local/share/mambaforge/etc/profile.d/conda.sh"
|
. "/home/$USER/.local/share/mambaforge/etc/profile.d/conda.sh"
|
||||||
else
|
else
|
||||||
export PATH="/home/sortion/.local/share/mambaforge/bin:$PATH"
|
export PATH="/home/$USER/.local/share/mambaforge/bin:$PATH"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
unset __conda_setup
|
unset __conda_setup
|
||||||
|
|
||||||
if [ -f "/home/sortion/.local/share/mambaforge/etc/profile.d/mamba.sh" ]; then
|
if [ -f "/home/$USER/.local/share/mambaforge/etc/profile.d/mamba.sh" ]; then
|
||||||
. "/home/sortion/.local/share/mambaforge/etc/profile.d/mamba.sh"
|
. "/home/$USER/.local/share/mambaforge/etc/profile.d/mamba.sh"
|
||||||
fi
|
fi
|
||||||
# <<< conda initialize <<<
|
# <<< conda initialize <<<
|
||||||
|
11
Makefile
11
Makefile
@ -3,9 +3,9 @@ all: pull install
|
|||||||
pull:
|
pull:
|
||||||
git pull
|
git pull
|
||||||
|
|
||||||
install: antigen source fish
|
install: antigen source emacs nvim
|
||||||
|
|
||||||
source: fishcfg
|
source: fish
|
||||||
cp ~/.dotfiles/.aliases ~/.aliases
|
cp ~/.dotfiles/.aliases ~/.aliases
|
||||||
cp ~/.dotfiles/.zshrc ~/.zshrc
|
cp ~/.dotfiles/.zshrc ~/.zshrc
|
||||||
cp ~/.dotfiles/.loadenv.sh ~/.loadenv.sh
|
cp ~/.dotfiles/.loadenv.sh ~/.loadenv.sh
|
||||||
@ -13,13 +13,18 @@ source: fishcfg
|
|||||||
cp ~/.dotfiles/.gitconfig ~/.gitconfig
|
cp ~/.dotfiles/.gitconfig ~/.gitconfig
|
||||||
cp ~/.dotfiles/.latexmkrc ~/.latexmkrc
|
cp ~/.dotfiles/.latexmkrc ~/.latexmkrc
|
||||||
|
|
||||||
fishcfg:
|
|
||||||
|
fish:
|
||||||
mkdir -p ~/.config/fish
|
mkdir -p ~/.config/fish
|
||||||
cp ./.config/fish/config.fish ~/.config/fish/config.fish
|
cp ./.config/fish/config.fish ~/.config/fish/config.fish
|
||||||
cp ./.aliases.fish ~/.aliases.fish
|
cp ./.aliases.fish ~/.aliases.fish
|
||||||
cp ./.config/starship.toml ~/.config/starship.toml
|
cp ./.config/starship.toml ~/.config/starship.toml
|
||||||
|
|
||||||
nvim:
|
nvim:
|
||||||
|
git clone ssh://gitea@forge.chapril.org:222/sortion/nvim.conf ~/.config/nvim/
|
||||||
|
|
||||||
|
emacs:
|
||||||
|
git clone ssh://gitea@forge.chapril.org:222/sortion/.emacs.d.git ~/.emacs.d/
|
||||||
|
|
||||||
antigen:
|
antigen:
|
||||||
git clone https://github.com/zsh-users/antigen.git
|
git clone https://github.com/zsh-users/antigen.git
|
||||||
|
Loading…
Reference in New Issue
Block a user