This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "CMake".
The branch, master has been updated via e17934c1834ef249107ba5fd46d5e6c2c9017534 (commit) via 5129e97285339ad0a481ffdd148bb9e09848a2f4 (commit) from 58da842063cc80e34ce3ae16aa8c5fb16cdc29dd (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e17934c1834ef249107ba5fd46d5e6c2c9017534 commit e17934c1834ef249107ba5fd46d5e6c2c9017534 Merge: 58da842063 5129e97285 Author: Brad King <brad.k...@kitware.com> AuthorDate: Mon Nov 25 15:52:55 2019 +0000 Commit: Kitware Robot <kwro...@kitware.com> CommitDate: Mon Nov 25 10:53:13 2019 -0500 Merge topic 'git-var' 5129e97285 setup-user: switch to git-var to check if username and e-mail are set Acked-by: Kitware Robot <kwro...@kitware.com> Merge-request: !4084 https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=5129e97285339ad0a481ffdd148bb9e09848a2f4 commit 5129e97285339ad0a481ffdd148bb9e09848a2f4 Author: Arkadiusz Drabczyk <arkadi...@drabczyk.org> AuthorDate: Sun Nov 24 19:10:56 2019 +0100 Commit: Arkadiusz Drabczyk <arkadi...@drabczyk.org> CommitDate: Sun Nov 24 19:10:56 2019 +0100 setup-user: switch to git-var to check if username and e-mail are set In git, apart from setting username and e-mail in .gitconfig it's also possible to set username in /etc/passwd and set e-mail using EMAIL environment variable. The advantage of this method is that other programs such as mutt or doxygen will pick up these settings up so there is no need to set them separately in each program. Current way of checking if username and e-mail are set using git config results in failure if they are set using this method. diff --git a/Utilities/GitSetup/setup-user b/Utilities/GitSetup/setup-user index 1af439c45e..0b98879491 100755 --- a/Utilities/GitSetup/setup-user +++ b/Utilities/GitSetup/setup-user @@ -20,12 +20,12 @@ # Project configuration instructions: NONE for (( ; ; )); do - user_name=$(git config user.name || echo '') && - user_email=$(git config user.email || echo '') && - if test -n "$user_name" -a -n "$user_email"; then + ident="$(git var GIT_AUTHOR_IDENT 2>/dev/null | rev | cut -d' ' -f3- | rev)" + + if test -n "$ident"; then echo 'Your commits will record as Author: - '"$user_name <$user_email>"' + '"$ident"' ' && read -ep 'Is the author name and email address above correct? [Y/n] ' correct && if test "$correct" != "n" -a "$correct" != "N"; then ----------------------------------------------------------------------- Summary of changes: Utilities/GitSetup/setup-user | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) hooks/post-receive -- CMake _______________________________________________ Cmake-commits mailing list Cmake-commits@cmake.org https://cmake.org/mailman/listinfo/cmake-commits