diff --git a/upload b/upload deleted file mode 100755 index 7e9fbd714703d2a26d3d02f98c00f35d0c647f6e..0000000000000000000000000000000000000000 --- a/upload +++ /dev/null @@ -1,41 +0,0 @@ -echo "UPLOADER 1.0" -if [ -z "$LFTP_PASSWORD" ] -then - echo -n "Heslo pro upload: " - read -s LFTP_PASSWORD; export LFTP_PASSWORD -fi - -USER=ok1kvk.cz-www-nove -HOST=krios.blueboard.cz -MAX_RETRIES=2 -RECONNECT_INTERVAL=5 - -echo "======================================================================" -echo "Uploading to $HOST" -if [ "$1" == "ftp" ]; then - echo "Using FTP" - /usr/bin/time -f "Upload took %e" -- lftp -e "set cmd:fail-exit yes;\ - set net:timeout 5;\ - set net:reconnect-interval-base $RECONNECT_INTERVAL;\ - set net:max-retries $MAX_RETRIES;\ - set ftp:ssl-allow no;\ - open --user $USER --env-password ftp://$HOST/;\ - mirror -c --verbose=9 -e -R -L ./build /;\ - exit 0;" - RET=$? - echo "LFTP finished with return code $RET" -else - echo "Using SFTP" - time lftp -e "set sftp:auto-confirm yes;\ - set cmd:fail-exit yes;\ - set net:timeout 5;\ - set net:reconnect-interval-base $RECONNECT_INTERVAL;\ - set net:max-retries $MAX_RETRIES;\ - open --user $USER --env-password -p 2121 sftp://$HOST/;\ - mirror -c --verbose=9 -e -R -L ./build /;\ - exit 0;" - RET=$? - echo "LFTP finished with return code $RET" -fi -exit 0 -