Revision a9f959b7
Added by David Sorber over 7 years ago
| software/hbkcd/scripts/hbkcd_add.sh | ||
|---|---|---|
|
command -v curl >/dev/null 2>&1 || { echo >&2 "Please install curl to use this script. Aborting."; exit 1; }
|
||
|
command -v jq >/dev/null 2>&1 || { echo >&2 "Please install jq to use this script. Aborting."; exit 1; }
|
||
|
|
||
|
INPUT_PATH=$(readlink -f $1)
|
||
|
curl -s -X POST -d '{"type": "add", "path": "'$INPUT_PATH'", "output": "'$2'"}' http://$ADDRESS:$PORT/command | jq
|
||
|
INPUT_PATH=$(readlink -f "$1")
|
||
|
#~ echo '{"type": "add", "path": "'"$INPUT_PATH"'", "output": "'"$2"'"}'
|
||
|
|
||
|
curl -s -d '{"type": "add", "path": "'"$INPUT_PATH"'", "output": "'"$2"'"}' -X POST http://$ADDRESS:$PORT/command | jq
|
||
Fixed bug in hbkcd_add.sh script that prevented adding paths with
spaces. Added item queued time to log. Created simple install script.
Version 0.1.2.