#!/bin/sh set -e set -u if [ $# -lt 2 ] ; then echo 'Usage: upload-release VERSION [DIR]' echo 'Must be called in directory with binaries or with path' exit 1 fi REL=`echo $1 | tr -d -c '0-9a-z.-'` if [ "x$REL" != "x$1" ] ; then echo "Invalid version: $1" exit 1 fi if [ $# -gt 1 ] ; then cd "$2" fi # Upload to our file server sftp -P 11022 files@klutz.phpmyadmin.net -f -b - <