From 7ac389a7380bed2fb1890ea97eeb60a5d47e665e Mon Sep 17 00:00:00 2001 From: Maschell Date: Sat, 13 May 2017 13:32:46 +0200 Subject: [PATCH] Uploading the languages to the app store nightlies --- ftpupload.sh | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/ftpupload.sh b/ftpupload.sh index 0998e17..2786bd1 100644 --- a/ftpupload.sh +++ b/ftpupload.sh @@ -8,7 +8,10 @@ for entry in "$TRAVIS_BUILD_DIR/wiiu/apps/hidtovpad"/*; do curl --ftp-create-dirs -T "${entry##*/}" -u $FTP_USER:$FTP_PASSWORD "$FTP_SERVER/${entry##*/}" > /dev/null 2>&1 done + IFS=$'\n' # make newlines the only separator + +# controller configs for f in `curl -u $FTP_USER:$FTP_PASSWORD $FTP_SERVER/sd/wiiu/controller/ --silent --use-ascii --list-only`; do if [ "$f" != "." ] && [ "$f" != ".." ]; then echo "Deleting sd/wiiu/controller/${f##*/}" @@ -21,9 +24,27 @@ cd $TRAVIS_BUILD_DIR/wiiu/controller for entry in "$TRAVIS_BUILD_DIR/wiiu/controller"/* do echo "Uploading ${entry##*/}" - curl --ftp-create-dirs -T "${entry##*/}" -u $FTP_USER:$FTP_PASSWORD "$FTP_SERVER/sd/wiiu/controller/${entry##*/}" > /dev/null 2>&1 + curl --ftp-create-dirs -T "${entry##*/}" -u $FTP_USER:$FTP_PASSWORD "$FTP_SERVER/sd/wiiu/apps/hidtovpad/languages/${entry##*/}" > /dev/null 2>&1 done + +# Language files +for f in `curl -u $FTP_USER:$FTP_PASSWORD $FTP_SERVER/sd/wiiu/controller/ --silent --use-ascii --list-only`; do + if [ "$f" != "." ] && [ "$f" != ".." ]; then + echo "Deleting sd/wiiu/apps/hidtovpad/languages/${f##*/}" + curl -v -u $FTP_USER:$FTP_PASSWORD ftp://$FTP_SERVER/ -Q "DELE sd/wiiu/apps/hidtovpad/languages/$f" --silent > /dev/null 2>&1 + fi +done + +cd $TRAVIS_BUILD_DIR/languages + +for entry in "$TRAVIS_BUILD_DIR/languages"/* +do + echo "Uploading ${entry##*/}" + curl --ftp-create-dirs -T "${entry##*/}" -u $FTP_USER:$FTP_PASSWORD "$FTP_SERVER/sd/wiiu/apps/hidtovpad/languages/${entry##*/}" > /dev/null 2>&1 +done + + curl -v -u $FTP_USER:$FTP_PASSWORD ftp://$FTP_SERVER/ -Q "DELE .deletetoupdate" --silent > /dev/null 2>&1 curl $REFRESH