Browse Source

Check dependencies

power-cycle
Luke Childs 5 years ago
parent
commit
b650825ff2
  1. 11
      karen

11
karen

@ -3,6 +3,17 @@
# karen watches for signals and executes triggers in the events dir
# karen gets triggered a lot
check_dependencies () {
for cmd in "$@"; do
if ! command -v $cmd >/dev/null 2>&1; then
echo "This script requires \"${cmd}\" to be installed"
exit 1
fi
done
}
check_dependencies fswatch readlink dirname
if [[ -n "$1" ]]; then
root_dir="$(readlink -f $1)"
else

Loading…
Cancel
Save