#!/bin/bash main(){ run_cli_install; } _install_cli(){ local name=$1; if $(! command -v "$name" &> /dev/null); then bash ./warn.sh "Installing cli tool: $name" if (pacman -S --needed "$name" --noconfirm >>/dev/null); then bash ./success.sh "Successfully installed cli tool: $name" else bash ./error.sh "Failed: $name" fi else bash ./warn.sh "Skipping: $name" fi } run_cli_install(){ echo "########################### Cli Tools #######################" local cli_tools=( "git" "vim" # <-- second to helix "helix" # <-- my fave editor "typescript" "typescript-language-server" "bash-language-server" "mingw-w64-x86_64-clang" # <-- expect failure "flatpak" # <-- good ol flatty, baby "fish" # <-- shell "less" "nodejs" # <-- hawk tuah "npm" # <-- need unfortunately for work stuff "tmux" # <-- multplexer "lazygit" "yazi" "wezterm" "ttf-nerd-fonts-symbols-mono" ) for i in "${cli_tools[@]}"; do _install_cli "$i"; done; } main;