From 29b4703b203aa0e296d6c26dc9a0f56a9030db65 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Sun, 5 Nov 2023 21:31:36 +0100 Subject: [PATCH] ||: is short for || true --- arch.sh | 8 ++++---- arch_wsl.sh | 10 +++++----- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/arch.sh b/arch.sh index abbc629..b029a12 100644 --- a/arch.sh +++ b/arch.sh @@ -145,7 +145,7 @@ main() { # === Rust == # Add Cargo packages from Rust mkdir -p "$HOME"/.cargo/bin - fish -c "fish_add_path $HOME/.cargo/bin | true" + fish -c "fish_add_path $HOME/.cargo/bin ||:" # Add cargo packages cargo install cargo-update cargo-cache @@ -363,7 +363,7 @@ main() { # === Python == # Add PIP packages from Python to the path mkdir -p "$HOME"/.local/bin - fish -c "fish_add_path /home/anri/.local/bin | true" + fish -c "fish_add_path /home/anri/.local/bin ||:" # === OCaml == # Init Opam and install stuff @@ -374,14 +374,14 @@ main() { wget -q ${repo}/dotfiles/.ocamlformat -O "$HOME"/.ocamlformat # Add Opam packages from OCaml mkdir -p "$HOME"/.opam/default/bin - fish -c "fish_add_path /home/anri/.opam/default/bin | true" + fish -c "fish_add_path /home/anri/.opam/default/bin ||:" # === Clang == wget -q ${repo}/dotfiles/.clang-format -O "$HOME"/.clang-format # === Perl == # Add perl packages to path - fish -c "fish_add_path /usr/bin/vendor_perl | true" + fish -c "fish_add_path /usr/bin/vendor_perl ||:" # === Discord == # Skip update diff --git a/arch_wsl.sh b/arch_wsl.sh index bc05111..aa8fd47 100644 --- a/arch_wsl.sh +++ b/arch_wsl.sh @@ -73,7 +73,7 @@ main() { # === Rust == # Add Cargo packages from Rust mkdir -p "$HOME"/.cargo/bin - fish -c "fish_add_path $HOME/.cargo/bin | true" + fish -c "fish_add_path $HOME/.cargo/bin ||:" # Add cargo packages cargo install cargo-update cargo-cache @@ -165,7 +165,7 @@ main() { # === Python == # Add PIP packages from Python mkdir -p "$HOME"/.local/bin - fish -c "fish_add_path $HOME/.local/bin | true" + fish -c "fish_add_path $HOME/.local/bin ||:" # === OCaml == # Init Opam and install stuff @@ -176,7 +176,7 @@ main() { wget -q ${repo}/dotfiles/.ocamlformat -O "$HOME"/.ocamlformat # Add Opam packages from OCaml mkdir -p "$HOME"/.opam/default/bin - fish -c "fish_add_path $HOME/.opam/default/bin | true" + fish -c "fish_add_path $HOME/.opam/default/bin ||:" # Fix dlllwt_unix_stubs.so shared object file fish -c "set -Ux CAML_LD_LIBRARY_PATH $(opam var stublibs)" @@ -192,7 +192,7 @@ main() { # === Perl == # Add perl packages to path - fish -c "fish_add_path /usr/bin/vendor_perl | true" + fish -c "fish_add_path /usr/bin/vendor_perl ||:" # === Emacs == # mkdir -p "$HOME"/.emacs.d @@ -213,7 +213,7 @@ main() { sudo npm i -g npm@latest # === Clear useless packages - pacman -Qqtd | sudo pacman --noconfirm -Rsn subsystemctl - 2> /dev/null || true + pacman -Qqtd | sudo pacman --noconfirm -Rsn subsystemctl - 2> /dev/null ||: echo -e "\nInstallation terminée !\nIl faut redémarrer WSL (dans Powershell = wsl --shutdown)." echo -e "---\nPense bien à paramétrer ton terminal, exemple avec Windows Terminal :"