20 lines
304 B
Text
20 lines
304 B
Text
|
#!/bin/bash
|
||
|
set -euo pipefail
|
||
|
|
||
|
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||
|
ROOT_DIR="$(dirname "$SCRIPT_DIR")"
|
||
|
. "$ROOT_DIR/config.sh"
|
||
|
|
||
|
function usage {
|
||
|
echo "Usage: $0 file"
|
||
|
exit 1
|
||
|
}
|
||
|
|
||
|
file=${1:-}
|
||
|
if [[ -z "$file" ]]; then
|
||
|
usage
|
||
|
fi
|
||
|
|
||
|
echo "Stapling $file"
|
||
|
xcrun stapler staple $file
|