diff options
author | xengineering <me@xengineering.eu> | 2024-06-24 19:53:57 +0200 |
---|---|---|
committer | xengineering <me@xengineering.eu> | 2024-06-24 19:53:57 +0200 |
commit | e8f1e4eae9725085929d19cba4d36dda809c8a89 (patch) | |
tree | d253bf8775659f8cfda354e5847a5c2123a68ea7 | |
parent | 787e177debd365c89ec195e61e2eda932df8e08a (diff) | |
download | dotfiles-e8f1e4eae9725085929d19cba4d36dda809c8a89.tar dotfiles-e8f1e4eae9725085929d19cba4d36dda809c8a89.tar.zst dotfiles-e8f1e4eae9725085929d19cba4d36dda809c8a89.zip |
bash: Check for required programs
This commit adds code to the .bashrc file which checks for required
programs on startup of bash. Thus it is easier to detect for the user if
essential programs are missing.
This will make it significantly easier to setup new machines.
-rw-r--r-- | .bashrc | 34 |
1 files changed, 34 insertions, 0 deletions
@@ -8,7 +8,41 @@ # variables GOPATH=$HOME/go export EDITOR=nvim +PROGRAMS=' +aerc +bemenu-run +brightnessctl +dunst +foot +gammastep +grim +htop +khard +lf +mpv +nvim +pactl +rifle +slurp +swappy +swappy +sway +swaylock +vdirsyncer +' +# check for missing programs +echo "$PROGRAMS" | while read -r program +do + if [ "$program" == '' ] + then + continue + fi + if ! command -v "$program" 2>&1 > /dev/null + then + echo "Program is missing: '$program'" + fi +done # alias definitions alias ls='ls --color=auto' |