Package: etckeeper Version: 1.9ubuntu1 Severity: normal Tags: upstream patch
Dear Maintainer, version 1.5 introduced a change which causes the Git configuration of the actual user being used when executed using sudo. However, the GIT_* (name, e-mail) variables are not exported, therefore Git does not find them and falls back to determining them itself. This results in an e-mail such as "host.(none)" which Git rejects as invalid. I have fixed the error by exporting the variables in the commit.d/50vcs-commit script, which seems to work. You can git pull the fix from the git-export branch at https://git.ikkoku.de/git/suraia/etckeeper Alternatively, I am attaching a patch for your convenience. * What led up to the situation? Upgrading from version 1.4 to 1.9 produced an error in the post-install hook (using "sudo aptitude"). -- System Information: Debian Release: wheezy/sid APT prefers saucy-updates APT policy: (500, 'saucy-updates'), (500, 'saucy-security'), (500, 'saucy') Architecture: amd64 (x86_64) Kernel: Linux 3.11.0-12-generic (SMP w/2 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages etckeeper depends on: ii debconf [debconf-2.0] 1.5.50ubuntu1 ii git 1:1.8.4.1-1~saucy1 ii hostname 3.13ubuntu1 Versions of packages etckeeper recommends: ii cron 3.0pl1-124ubuntu2 Versions of packages etckeeper suggests: ii sudo 1.8.6p3-0ubuntu3 -- Configuration Files: /etc/etckeeper/etckeeper.conf changed [not included] -- debconf information excluded
>From c9e372abf2fc40a0ef07599e54f2b2755269a067 Mon Sep 17 00:00:00 2001 From: Michael Kuhn <sur...@ikkoku.de> Date: Sun, 3 Nov 2013 11:32:32 +0100 Subject: [PATCH] Export Git variables, otherwise Git falls back to determining them itself. --- commit.d/50vcs-commit | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/commit.d/50vcs-commit b/commit.d/50vcs-commit index 3a4c819..5987ad6 100755 --- a/commit.d/50vcs-commit +++ b/commit.d/50vcs-commit @@ -46,14 +46,14 @@ if [ "$VCS" = git ] && [ -d .git ]; then USER_HOME="$(perl -e 'print ((getpwnam(shift()))[7])' "$USER")" if [ -n "$USER_HOME" ] && [ -e "$USER_HOME/.gitconfig" ]; then if [ -z "$GIT_AUTHOR_NAME" ]; then - GIT_AUTHOR_NAME="$(git config -f "$USER_HOME/.gitconfig" user.name)" || true + export GIT_AUTHOR_NAME="$(git config -f "$USER_HOME/.gitconfig" user.name)" || true fi if [ -z "$GIT_AUTHOR_EMAIL" ]; then - GIT_AUTHOR_EMAIL="$(git config -f "$USER_HOME/.gitconfig" user.email)" || true + export GIT_AUTHOR_EMAIL="$(git config -f "$USER_HOME/.gitconfig" user.email)" || true fi fi if [ -z "$GIT_COMMITTER_EMAIL" ]; then - GIT_COMMITER_EMAIL="$(git config --global user.email)" || true + export GIT_COMMITER_EMAIL="$(git config --global user.email)" || true fi if [ -z "$GIT_AUTHOR_NAME" ]; then -- 1.8.4.2