Fixes
This commit is contained in:
parent
d5800bed8b
commit
1be1b65904
2 changed files with 2 additions and 2 deletions
2
bin/pbin
2
bin/pbin
|
@ -2,4 +2,4 @@
|
|||
|
||||
f="${1}"
|
||||
uuid="$(uuidgen -t)"
|
||||
upload "${f}" "${uuid}/${f}" "pastes"
|
||||
upload "${f}" "${uuid}/$(basename "$f")" "pastes"
|
||||
|
|
|
@ -18,7 +18,7 @@ if [ "$(curl -s -o /dev/null -w "%{http_code}" "${url}")" -eq 200 ]; then
|
|||
exit 3
|
||||
fi
|
||||
|
||||
ssh "$HOST" mkdir -p "${internal_dir}"
|
||||
ssh "$HOST" mkdir -p "$(dirname "${internal_dir}/${fname}")"
|
||||
rsync --progress --no-owner --no-group --chmod=644 --ignore-existing "${f}" "${HOST}:${internal_dir}/${fname}" | tee "${HOME}/.upload.log"
|
||||
code="$?"
|
||||
echo "Uploaded to: ${url}"
|
||||
|
|
Reference in a new issue