summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxengineering <me@xengineering.eu>2024-06-24 19:53:57 +0200
committerxengineering <me@xengineering.eu>2024-06-24 19:53:57 +0200
commit2caf61b7dceebc12f13addb619ef14836b433bae (patch)
treed253bf8775659f8cfda354e5847a5c2123a68ea7
parent3765d66c7941e3fc75773d89f4b1464171c39a75 (diff)
downloaddotfiles-2caf61b7dceebc12f13addb619ef14836b433bae.tar
dotfiles-2caf61b7dceebc12f13addb619ef14836b433bae.tar.zst
dotfiles-2caf61b7dceebc12f13addb619ef14836b433bae.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--.bashrc34
1 files changed, 34 insertions, 0 deletions
diff --git a/.bashrc b/.bashrc
index 0c48c49..3e1966c 100644
--- a/.bashrc
+++ b/.bashrc
@@ -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'