--- src/platform/darwin.sh.orig 2013-08-15 23:55:27.000000000 +0800 +++ src/platform/darwin.sh 2013-08-15 23:57:20.000000000 +0800 @@ -2,20 +2,21 @@ # This file is licensed under the GPLv2+. Please see COPYING for more information. clip() { - before="$(pbpaste | openssl base64)" + before="$(pbpaste | base64)" echo -n "$1" | pbcopy ( sleep 45 - now="$(pbpaste | openssl base64)" - if [[ $now != $(echo -n "$1" | openssl base64) ]]; then + now="$(pbpaste | base64)" + if [[ $now != $(echo -n "$1" | base64) ]]; then before="$now" fi - echo "$before" | openssl base64 -d | pbcopy + echo "$before" | base64 -d | pbcopy ) & disown echo "Copied $2 to clipboard. Will clear in 45 seconds." } tmpdir() { + PATH="${PATH}:/sbin:/usr/sbin" cleanup_tmp() { [[ -d $tmp_dir ]] || return rm -rf "$tmp_file" "$tmp_dir" 2>/dev/null @@ -31,4 +32,4 @@ mount -t hfs -o noatime -o nobrowse "$ramdisk_dev" "$tmp_dir" || exit 1 } -GETOPT="$(brew --prefix gnu-getopt 2>/dev/null || echo /usr/local)/bin/getopt" +GETOPT="getopt-long"