[sysadmin-bin] Make sure the hooks section is added, the best option I could find for gitlab was landing it on the
- From: Andrea Veri <av src gnome org>
- To: gnome-sysadmin gnome org,commits-list gnome org
- Subject: [sysadmin-bin] Make sure the hooks section is added, the best option I could find for gitlab was landing it on the
- Date: Fri, 30 Jun 2017 09:05:48 +0000 (UTC)
commit b2f9925bab57f8c216151380270fddf28b2b0dbc
Author: Andrea Veri <averi redhat com>
Date: Fri Jun 30 11:05:38 2017 +0200
Make sure the hooks section is added, the best option I could find for gitlab was landing it on the
pre-receive hook
git/gnome-pre-receive | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/git/gnome-pre-receive b/git/gnome-pre-receive
index 296021f..c8e1487 100755
--- a/git/gnome-pre-receive
+++ b/git/gnome-pre-receive
@@ -63,6 +63,18 @@ EOF
exit 1
fi
+if [ $(hostname) == 'gitlab.gnome.org' ] || [ $(hostname) == 'gitlab-test.gnome.org' ]; then
+ cd $GIT_DIR
+ cat config | grep -q 'hooks.emailprefix'
+ if [ "$?" -eq 1 ]; then
+ git config hooks.emailprefix ""
+ fi
+ cat config | grep -q 'hooks.emailprefix'
+ if [ "$?" -eq 1 ]; then
+ git config hooks.mailinglist commits-list gnome org
+ fi
+fi
+
my_uid=`id -u`
translations_uid=`id -u translations`
[ $? == 0 ] || exit 1
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]