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,9 +1,11 @@
#!/bin/sh -e #!/bin/sh -e
if [ "$(uname -s)" = "Darwin" ]; then
CUT="gcut" CUT="gcut"
if ! command -v "${CUT}" >/dev/null 2>&1; then if ! command -v "${CUT}" >/dev/null 2>&1; then
CUT="cut" CUT="cut"
fi fi
fi
file_changed() { file_changed() {
if [ ! -f "$1" ]; then if [ ! -f "$1" ]; then

View File

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