Only do command checks on Darwin.

master
Icedream 2018-07-26 11:56:01 +02:00
parent dcfbdbb14c
commit 2100cbdf1f
Signed by: icedream
GPG Key ID: 1573F6D8EFE4D0CF
2 changed files with 10 additions and 6 deletions

View File

@ -1,8 +1,10 @@
#!/bin/sh -e #!/bin/sh -e
CUT="gcut" if [ "$(uname -s)" = "Darwin" ]; then
if ! command -v "${CUT}" >/dev/null 2>&1; then CUT="gcut"
CUT="cut" if ! command -v "${CUT}" >/dev/null 2>&1; then
CUT="cut"
fi
fi fi
file_changed() { file_changed() {

View File

@ -1,8 +1,10 @@
#!/bin/sh -e #!/bin/sh -e
READLINK="greadlink" if [ "$(uname -s)" = "Darwin" ]; then
if ! command -v "${READLINK}" >/dev/null 2>&1; then READLINK="greadlink"
READLINK="readlink" if ! command -v "${READLINK}" >/dev/null 2>&1; then
READLINK="readlink"
fi
fi fi
install_files() { install_files() {