This commit is contained in:
parent
b75f29b39b
commit
0983eccacc
5
sos/sos
5
sos/sos
@ -11,7 +11,8 @@ set -euo pipefail
|
|||||||
|
|
||||||
# get dropshell
|
# get dropshell
|
||||||
TEMP_DIR=$(mktemp -d)
|
TEMP_DIR=$(mktemp -d)
|
||||||
curl -L -s -o "${TEMP_DIR}/dropshell" "https://getbin.xyz/dropshell"
|
ARCH=$(uname -m)
|
||||||
|
curl -L -s -o "${TEMP_DIR}/dropshell" "https://getbin.xyz/dropshell.${ARCH}" || die "Failed to download dropshell"
|
||||||
chmod +x "${TEMP_DIR}/dropshell"
|
chmod +x "${TEMP_DIR}/dropshell"
|
||||||
trap 'rm -rf "${TEMP_DIR}"' EXIT
|
trap 'rm -rf "${TEMP_DIR}"' EXIT
|
||||||
DROPSHELL="${TEMP_DIR}/dropshell"
|
DROPSHELL="${TEMP_DIR}/dropshell"
|
||||||
@ -102,7 +103,7 @@ EOF
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# trip whitespace from the file path
|
# trip whitespace from the file path
|
||||||
LOCALHASH=$("${DROPSHELL}" hash "${FILEPATH}" | tr -d '[:space:]')
|
LOCALHASH=$("${DROPSHELL}" hash "${file}" | tr -d '[:space:]')
|
||||||
echo "Local hash: $LOCALHASH"
|
echo "Local hash: $LOCALHASH"
|
||||||
|
|
||||||
FILELINE="-F \"file=@${file}\""
|
FILELINE="-F \"file=@${file}\""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user