diff options
author | Joey Hess <joey@kodama.kitenet.net> | 2008-03-25 20:53:02 -0400 |
---|---|---|
committer | Joey Hess <joey@kodama.kitenet.net> | 2008-03-25 20:53:02 -0400 |
commit | b4b7c0996c73291b34f0566f74ad2513c44a6371 (patch) | |
tree | e1c15d4975fb7b813b044ee943b93b373a5c2352 /post-install.d/50vcs-commit | |
parent | da1632bd6dca9b3ba46ab74809e409a74dd99a24 (diff) |
Keep track of what packages change state during an installation, and include that in the commit message at the end.
Diffstat (limited to 'post-install.d/50vcs-commit')
-rwxr-xr-x | post-install.d/50vcs-commit | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/post-install.d/50vcs-commit b/post-install.d/50vcs-commit index 581e310..76fb668 100755 --- a/post-install.d/50vcs-commit +++ b/post-install.d/50vcs-commit @@ -1,6 +1,17 @@ #!/bin/sh set -e + +pl="/var/cache/etckeeper/packagelist" +NL=" +" if etckeeper unclean; then - etckeeper commit "committing changes after $HIGHLEVEL_PACKAGE_MANAGER run" + message="committing changes in /etc after $HIGHLEVEL_PACKAGE_MANAGER run" + + if [ -e $pl.pre-install ]; then + message="$message$NL$(etckeeper list-installed | diff -U0 $pl.pre-install - | tail -n+4)" + rm -f $pl.pre-install + fi + + etckeeper commit "$(printf "$message")" fi |