move aliases to conf.d file

This commit is contained in:
Mylloon 2023-03-12 23:35:32 +01:00
parent 79d4396425
commit 4dee05263a
Signed by: Anri
GPG key ID: A82D63DFF8D1317F
2 changed files with 48 additions and 35 deletions

View file

@ -0,0 +1,47 @@
abbr ls 'exa --git --icons -gl'
abbr cp 'cp -rv'
abbr rm 'rm -rf'
abbr mgcc 'clear; gcc -Wall -Wextra -Wshadow -Wcast-align -Wstrict-prototypes \
| -fanalyzer -fsanitize=undefined -g main.c && ./a.out; rm a.out 2> /dev/null'
abbr vgcc 'clear; gcc -Wall -Wextra -Wshadow -Wcast-align -Wstrict-prototypes \
| -fanalyzer -fsanitize=undefined -g main.c && valgrind --leak-check=full \
| --show-leak-kinds=all --track-origins=yes -s ./a.out; rm a.out 2> /dev/null'
abbr mg++ 'clear; g++ -Wall -Wextra -Wshadow -Wnon-virtual-dtor -pedantic -g \
| -Wold-style-cast -Wsign-conversion main.cpp && ./a.out; rm a.out 2> /dev/null'
abbr vg++ 'clear; g++ -Wall -Wextra -Wshadow -Wnon-virtual-dtor -pedantic -g \
| -Wold-style-cast -Wsign-conversion main.cpp && valgrind --leak-check=full \
| --show-leak-kinds=all --track-origins=yes -s ./a.out; rm a.out 2> /dev/null'
abbr mmake 'clear; make && ./main; make clean 2> /dev/null'
abbr vmake 'clear; make && valgrind --leak-check=full --show-leak-kinds=all \
| --track-origins=yes -s ./main; make clean 2> /dev/null'
abbr activate 'source bin/activate.fish'
abbr c 'command'
abbr vs 'code .'
abbr untgz 'tar xvzf'
abbr tgz 'tar czf \"Archive.tar.gz\"'
abbr - 'cd -'
abbr cd.. 'cd ..'
abbr ..2 'cd ../..'
abbr ..3 'cd ../../..'
abbr ..4 'cd ../../../..'
abbr ..5 'cd ../../../../..'
abbr cat 'bat'
abbr nano 'micro'
abbr bigupdate 'yay -Syu --noconfirm && tldr --update && yes | sdk update && \
| yes | sdk upgrade java'
abbr d 'explorer.exe .'
abbr gc 'git clone'
abbr cl 'cat src/**.* | sed \'/^\s*$/d\' | wc -l'
abbr mirrors_update "curl -s \
| 'https://archlinux.org/mirrorlist/?country=FR&country=GB&protocol=https&use_mirror_status=on' \
| | sed -e 's/^#Server/Server/' -e '/^#/d' | sudo bash -c 'rankmirrors -n 7 - > \
| /etc/pacman.d/mirrorlist' && sudo pacman -Syy"
abbr ocamlbuild 'ocamlbuild -no-hygiene'
abbr opamupdate 'opam update && opam upgrade -y'
abbr yay-rebuild 'checkrebuild | awk \'{print \$2}\' | xargs -r yay -S \
| --rebuildtree --noconfirm'
abbr pacman-clean 'sudo pacman -Rsn \$(pacman -Qqtd) --noconfirm'
abbr diff 'delta'
abbr grep 'grep -Irni \'txt\' .'
abbr unison 'unison ~/src ~/u_dest'
abbr zip 'zip -r \"archive.zip\" dossier'

View file

@ -127,41 +127,7 @@ main() {
# EXA colors
fish -c "set -Ux EXA_COLORS 'di=1;36:da=35'"
# Add aliases
fish -c "abbr ls 'exa --git --icons -gl'"
fish -c "abbr cp 'cp -rv'"
fish -c "abbr rm 'rm -rf'"
fish -c "abbr mgcc 'clear; gcc -Wall -Wextra -Wshadow -Wcast-align -Wstrict-prototypes -fanalyzer -fsanitize=undefined -g main.c && ./a.out; rm a.out 2> /dev/null'"
fish -c "abbr vgcc 'clear; gcc -Wall -Wextra -Wshadow -Wcast-align -Wstrict-prototypes -fanalyzer -fsanitize=undefined -g main.c && valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes -s ./a.out; rm a.out 2> /dev/null'"
fish -c "abbr mg++ 'clear; g++ -Wall -Wextra -Wshadow -Wnon-virtual-dtor -pedantic -g -Wold-style-cast -Wsign-conversion main.cpp && ./a.out; rm a.out 2> /dev/null'"
fish -c "abbr vg++ 'clear; g++ -Wall -Wextra -Wshadow -Wnon-virtual-dtor -pedantic -g -Wold-style-cast -Wsign-conversion main.cpp && valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes -s ./a.out; rm a.out 2> /dev/null'"
fish -c "abbr mmake 'clear; make && ./main; make clean 2> /dev/null'"
fish -c "abbr vmake 'clear; make && valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes -s ./main; make clean 2> /dev/null'"
fish -c "abbr activate 'source bin/activate.fish'"
fish -c "abbr c 'command'"
fish -c "abbr vs 'code .'"
fish -c "abbr untgz 'tar xvzf'"
fish -c "abbr tgz 'tar czf \"Archive.tar.gz\"'"
fish -c "abbr - 'cd -'"
fish -c "abbr cd.. 'cd ..'"
fish -c "abbr ..2 'cd ../..'"
fish -c "abbr ..3 'cd ../../..'"
fish -c "abbr ..4 'cd ../../../..'"
fish -c "abbr ..5 'cd ../../../../..'"
fish -c "abbr cat 'bat'"
fish -c "abbr nano 'micro'"
fish -c "abbr bigupdate 'yay -Syu --noconfirm && tldr --update && yes | sdk update && yes | sdk upgrade java'"
fish -c "abbr d 'explorer.exe .'"
fish -c "abbr gc 'git clone'"
fish -c "abbr cl 'cat src/**.* | sed \'/^\s*$/d\' | wc -l'"
fish -c "abbr mirrors_update \"curl -s 'https://archlinux.org/mirrorlist/?country=FR&country=GB&protocol=https&use_mirror_status=on' | sed -e 's/^#Server/Server/' -e '/^#/d' | sudo bash -c 'rankmirrors -n 7 - > /etc/pacman.d/mirrorlist' && sudo pacman -Syy\""
fish -c "abbr ocamlbuild 'ocamlbuild -no-hygiene'"
fish -c "abbr opamupdate 'opam update && opam upgrade -y'"
fish -c "abbr yay-rebuild 'checkrebuild | awk \'{print \$2}\' | xargs -r yay -S --rebuildtree --noconfirm'"
fish -c "abbr pacman-clean 'sudo pacman -Rsn \$(pacman -Qqtd) --noconfirm'"
fish -c "abbr diff 'delta'"
fish -c "abbr grep 'grep -Irni \'txt\' .'"
fish -c "abbr unison 'unison ~/src ~/u_dest'"
fish -c "abbr zip 'zip -r \"archive.zip\" dossier'"
wget -q https://git.mylloon.fr/Anri/confOS/raw/branch/main/.config/fish/conf.d/abbr_wsl.fish -O "$HOME"/.config/fish/conf.d/abbr_wsl.fish
# === Micro configuration ==
git config --global core.editor "micro"