[sysadmin-bin] Make good use of the GL_USERNAME environment variable (https://gitlab.com/gitlab-org/gitlab-ce/issue



commit 777c490290b5409d0376aa92510fb7bc65fad998
Author: Andrea Veri <averi redhat com>
Date:   Mon Oct 23 14:00:37 2017 +0200

    Make good use of the GL_USERNAME environment variable 
(https://gitlab.com/gitlab-org/gitlab-ce/issues/24945)

 git/log-push |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/git/log-push b/git/log-push
index 5a539bb..7f15e13 100755
--- a/git/log-push
+++ b/git/log-push
@@ -14,7 +14,11 @@ fi
 
 LOG_FILE="$GIT_DIR/gnome_pushlog"
 
-user=$(whoami)
+if [[ $(hostname) =~ gitlab(\-test|)\.gnome\.org$ ]]; then
+    user=$GL_USERNAME
+else
+    user=$(whoami)
+fi
 # RFC 822 date with a fixed UTC timezone (Thu, 05 Feb 2009 19:25:44 +0000)
 date=$(TZ=UTC date -R)
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]