X-Git-Url: https://git.phdru.name/?a=blobdiff_plain;f=configure-sf;h=75ae13e9774b4d4169cd3b3d2ba83f889d48da07;hb=0f2ee1cb405df27ca3d71d6794e16e617187e97d;hp=cd3df5a8ab4ecf247c665826783b6c4674a8dd35;hpb=e055b2c4f39576b3fe7fe9aa3da4d3ce302f6fbb;p=git-scripts.git diff --git a/configure-sf b/configure-sf index cd3df5a..75ae13e 100755 --- a/configure-sf +++ b/configure-sf @@ -3,7 +3,7 @@ # Origin: http://blog.gorwits.me.uk/index.html%3Fp=529.html if [ -z "$3" ]; then - echo "Usage: $0 PROJECTNAME REPONAME MLIST [prefix]" >&2 + echo "Usage: $0 PROJECTNAME REPONAME MLIST prefix [maxlines]" >&2 exit 1 fi @@ -11,6 +11,7 @@ PROJECTNAME="$1" REPONAME="$2" MLIST="$3" prefix="$4" +maxlines="$5" cd /home/git/p/"$PROJECTNAME/$REPONAME".git && echo "$PROJECTNAME git repository ($REPONAME)" > description @@ -19,14 +20,13 @@ echo "$PROJECTNAME git repository ($REPONAME)" > description #curl -L -o hooks/post-receive-user https://git.kernel.org/cgit/git/git.git/plain/contrib/hooks/post-receive-email && #http://tinyurl.com/git-post-commit-email wget -O hooks/post-receive-user https://git.kernel.org/cgit/git/git.git/plain/contrib/hooks/post-receive-email && -chmod +x hooks/post-receive-user && -#chmod g+w hooks/post-receive-user && +chmod u=rwx,go=rx hooks/post-receive-user && -git config hooks.diffopts "--stat --summary --find-copies-harder -p" -git config hooks.emailmaxlines 500 && -if [ -n "$prefix" ]; then - git config hooks.emailprefix "$prefix" +#git config hooks.diffopts "--stat --summary --find-copies-harder -p" && +if [ -n "$maxlines" ]; then + git config hooks.emailmaxlines "$maxlines" fi && +git config hooks.emailprefix "$prefix" && git config hooks.envelopesender noreply@sourceforge.net && -git config hooks.mailinglist $MLIST@lists.sourceforge.net -#git config hooks.showrev "t=%s; printf 'http://$PROJECTNAME.git.sourceforge.net/git/gitweb.cgi?p=$PROJECTNAME/$REPONAME;a=commitdiff;h=%%s' ; echo;echo; git show -C ; echo" +git config hooks.mailinglist $MLIST@lists.sourceforge.net && +exec git config hooks.showrev "t=%s; printf 'http://sourceforge.net/p/$PROJECTNAME/$REPONAME/ci/%%s' \$t; echo;echo; git show -C \$t; echo"