This is an automated email from the git hooks/post-receive script. x2go pushed a change to branch master in repository maintenancescripts. from 3ce2087 git/hooks/common.sh: fix bad hooks error: it's git rev-parse --is-bare-repository, not git rev-parse --is-bare-directory. new f66cc65 git/misc: add original setup-repository and update-repository-posixacls scripts new 42f9bda git/misc/setup-repository: use bash. new f271f65 git/misc/setup-repository: tweak usage message. The 3 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Summary of changes: git/misc/setup-repository | 95 ++++++++++++++++++++++++++++++++++ git/misc/update-repository-posixacls | 58 +++++++++++++++++++++ 2 files changed, 153 insertions(+) create mode 100755 git/misc/setup-repository create mode 100755 git/misc/update-repository-posixacls -- Alioth's /srv/git/code.x2go.org/maintenancescripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/maintenancescripts.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository maintenancescripts. commit 42f9bda125adbe7bce8c0da17bb9b187d38d8f22 Author: Mihai Moldovan <ionic@ionic.de> Date: Mon Mar 9 00:15:21 2015 +0100 git/misc/setup-repository: use bash. --- git/misc/setup-repository | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git/misc/setup-repository b/git/misc/setup-repository index a1cc74c..8c13a50 100755 --- a/git/misc/setup-repository +++ b/git/misc/setup-repository @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # This script is used to setup a git repository. -- Alioth's /srv/git/code.x2go.org/maintenancescripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/maintenancescripts.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository maintenancescripts. commit f66cc657466df2a311b2257b3d5d2c9d19215acc Author: Mihai Moldovan <ionic@ionic.de> Date: Sun Mar 8 23:52:19 2015 +0100 git/misc: add original setup-repository and update-repository-posixacls scripts --- git/misc/setup-repository | 95 ++++++++++++++++++++++++++++++++++ git/misc/update-repository-posixacls | 58 +++++++++++++++++++++ 2 files changed, 153 insertions(+) diff --git a/git/misc/setup-repository b/git/misc/setup-repository new file mode 100755 index 0000000..a1cc74c --- /dev/null +++ b/git/misc/setup-repository @@ -0,0 +1,95 @@ +#!/bin/sh + +# This script is used to setup a git repository. + +set -e + +USAGE="\n\ +This script is used to perform the operations needed to create a git\n\ +repository for X2go upstream.\n\ +\n\ +Usage: setup-repository <package> '<description>'\n\ +\n\ +Options: + <package> is the package name a git repository is being created for.\n\ + <description> is a description for the git repository.\n\ + It should be something like 'Packaging for <package>'.\n" + +if [ "$#" -ne "2" ]; then + echo -e "${USAGE}" + exit 1 +fi + +PACKAGE="$1" +DESCRIPTION="$2" + +# Create the repository +mkdir $PACKAGE.git +cd $PACKAGE.git +/usr/bin/git --bare init --shared +git config --add core.logallrefupdates true + +# Add the repository description +echo "$DESCRIPTION" >description + +# Enable the hook scripts +[ -f hooks/post-receive ] || { + cp -L /srv/git/_hooks_/post-receive._code.x2go.org_ hooks/post-receive.tmp + chmod 0660 hooks/post-receive.tmp +} + +[ -f hooks/update ] || { + cp -L /srv/git/_hooks_/update._code.x2go.org_ hooks/update.tmp + chmod 0660 hooks/update.tmp +} + +# set up ACLs +[ -f info/allowed-users ] || cat > info/allowed-users.tmp <<-EOF; +# master branch ++refs/heads/master x2go ++refs/heads/master x2go-admin ++refs/heads/master hmg ++refs/heads/master ncryer ++refs/heads/master mike + +# release branch ++refs/heads/release x2go-admin ++refs/heads/release mike ++refs/heads/release hmg ++refs/heads/release ncryer + +# pristine-tar branch ++refs/heads/pristine-tar x2go-admin ++refs/heads/pristine-tar mike ++refs/heads/pristine-tar hmg ++refs/heads/pristine-tar ncryer +EOF + +chmod 0660 info/allowed-users.tmp + +[ -f info/allowed-groups ] || cat > info/allowed-groups.tmp <<-EOF +# no group ACLs defined +EOF +chmod 0660 info/allowed-groups.tmp + +# tweak the Git configuration +git config --add hooks.mailinglist "x2go-commits@lists.x2go.org" +git config --add hooks.replyto "x2go-dev@lists.x2go.org" +git config --add hooks.announcelist "x2go-tags@lists.x2go.org" +git config --add hooks.envelopesender "git-admin@x2go.org" +git config --add hooks.emailprefix "" +git config --add hooks.showdiff "true" + +git config --add hooks.denycreatebranch false + + +mv config config.tmp +chmod 0660 config.tmp +mv description description.tmp +chmod 0660 description.tmp +mv info/exclude info/exclude.tmp +chmod 0660 info/exclude.tmp + +# Go back to the parent directory +cd .. + diff --git a/git/misc/update-repository-posixacls b/git/misc/update-repository-posixacls new file mode 100755 index 0000000..ae3c663 --- /dev/null +++ b/git/misc/update-repository-posixacls @@ -0,0 +1,58 @@ +#!/bin/sh + +# This script is used to move ownership of certain repos files after setup +# from x2go user to x2go-admin user + +set -e + +PACKAGE="$1" + +cd "$PACKAGE.git" + +# hooks +[ -f hooks/post-receive.tmp ] && { + cp hooks/post-receive.tmp hooks/post-receive + chmod 0755 hooks/post-receive + rm hooks/post-receive.tmp +} + +[ -f hooks/update.tmp ] && { + cp hooks/update.tmp hooks/update + chmod 0755 hooks/update + rm hooks/update.tmp +} + +# ACLs +[ -f info/allowed-users.tmp ] && { + cp info/allowed-users.tmp info/allowed-users + chmod 0640 info/allowed-users + rm info/allowed-users.tmp +} + +[ -f info/allowed-groups.tmp ] && { + cp info/allowed-groups.tmp info/allowed-groups + chmod 0640 info/allowed-groups + rm info/allowed-groups.tmp +} + +# configuration +[ -f config.tmp ] && { + cp config.tmp config + chmod 0644 config + rm config.tmp +} + +[ -f description.tmp ] && { + cp description.tmp description + chmod 0644 description + rm description.tmp +} + +[ -f info/exclude.tmp ] && { + cp info/exclude.tmp info/exclude + chmod 0644 info/exclude + rm info/exclude.tmp +} +# Go back to the parent directory +cd .. + -- Alioth's /srv/git/code.x2go.org/maintenancescripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/maintenancescripts.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository maintenancescripts. commit f271f65ff6cf1018543cae3c8a865f881902ca34 Author: Mihai Moldovan <ionic@ionic.de> Date: Mon Mar 9 00:16:10 2015 +0100 git/misc/setup-repository: tweak usage message. --- git/misc/setup-repository | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/git/misc/setup-repository b/git/misc/setup-repository index 8c13a50..1594cb9 100755 --- a/git/misc/setup-repository +++ b/git/misc/setup-repository @@ -4,16 +4,16 @@ set -e -USAGE="\n\ -This script is used to perform the operations needed to create a git\n\ -repository for X2go upstream.\n\ -\n\ -Usage: setup-repository <package> '<description>'\n\ -\n\ +USAGE="\ +This script is used to perform the operations needed to create a git +repository for X2Go upstream. + +Usage: $(basename ${0}) <package> '<description>' + Options: - <package> is the package name a git repository is being created for.\n\ - <description> is a description for the git repository.\n\ - It should be something like 'Packaging for <package>'.\n" +\t<package> is the package name a git repository is being created for. +\t<description> is a description for the git repository. +\t\tIt should be something like 'Packaging for <package>'." if [ "$#" -ne "2" ]; then echo -e "${USAGE}" -- Alioth's /srv/git/code.x2go.org/maintenancescripts.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/maintenancescripts.git