From 7634646bc1a03d0c0a2cad34bb62d0735b020c66 Mon Sep 17 00:00:00 2001 From: jtsiomb Date: Thu, 12 Mar 2015 19:53:32 +0000 Subject: [PATCH] added handy upload script which uses rsync to copy all modified files git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1757 7f0cb862-5218-0410-a997-914c9d46530a --- .gitattributes | 1 + freeglut/web-src/upload | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100755 freeglut/web-src/upload diff --git a/.gitattributes b/.gitattributes index 43bc6cf..324dd26 100644 --- a/.gitattributes +++ b/.gitattributes @@ -173,3 +173,4 @@ freeglut/web-src/news.php svn_keywords=Author+Date+Id+Revision freeglut/web-src/progress.php svn_keywords=Author+Date+Id+Revision freeglut/web-src/template.php svn_keywords=Author+Date+Id+Revision freeglut/web-src/uinfo.php svn_keywords=Author+Date+Id+Revision +freeglut/web-src/upload -text diff --git a/freeglut/web-src/upload b/freeglut/web-src/upload new file mode 100755 index 0000000..b37d43e --- /dev/null +++ b/freeglut/web-src/upload @@ -0,0 +1,21 @@ +#!/bin/sh + +if [ -n "$1" ]; then + user=$1 +else + # read the username out of .sfuser + if [ -f .sfuser ]; then + user=$(cat .sfuser) + else + user=$USER + fi + + if [ -z "$user" ]; then + echo "please pass your sourceforge username as argument, or create a .sfuser file" >&2 + exit 1 + fi +fi + +echo "connecting as user: $user ..." +rsync -vr --exclude='.sfuser' --exclude '*.swp' \ + --rsh="ssh -l $user" * $user,freeglut@web.sourceforge.net:htdocs/