diff options
author | Joey Hess <joey@kodama.kitenet.net> | 2008-01-04 18:46:24 -0500 |
---|---|---|
committer | Joey Hess <joey@kodama.kitenet.net> | 2008-01-04 18:46:24 -0500 |
commit | bbc7e253bae2b32cdfcb32ecf9c00b2f44756a81 (patch) | |
tree | 2483c828d80dbe5e35f9035b67e065ef80684eb9 /pre-install.d/50uncommitted-changes | |
parent | 653f6869335fffe2b0483991c63248e11974dd79 (diff) |
* Commit removed files in the pre-install hook to git, as was already done
for hg. Avoided changing the debconf template so bubulle doesn't murder
me; the current wording is just vague enough to still work with the
current behavior.
Diffstat (limited to 'pre-install.d/50uncommitted-changes')
-rwxr-xr-x | pre-install.d/50uncommitted-changes | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/pre-install.d/50uncommitted-changes b/pre-install.d/50uncommitted-changes index 3bfc037..f4c0f0f 100755 --- a/pre-install.d/50uncommitted-changes +++ b/pre-install.d/50uncommitted-changes @@ -22,6 +22,11 @@ commit() { if [ "$VCS" = git ]; then git add . + for file in $(git ls-files --deleted); do + if [ ! -d "$file" ]; then + git rm --quiet "$file" + fi + done git commit $GIT_COMMIT_OPTIONS -m "$message" elif [ "$VCS" = hg ]; then hg addremove . |