summaryrefslogtreecommitdiff
path: root/Command
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-01-17 14:11:01 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-01-17 14:11:01 -0400
commitea5f083bfeee7cd106763bff1c37b7fb79996046 (patch)
treed15a8ecb8349e0cfec2b5c5992f11e5e4e92435d /Command
parentc42a2d99591e1df909f8649b71241fec48b2db78 (diff)
avoid running pre-commit hook in direct mode
The code that handles committing unlocked files in indirect mode did something unexpected and data lossy.
Diffstat (limited to 'Command')
-rw-r--r--Command/PreCommit.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Command/PreCommit.hs b/Command/PreCommit.hs
index e675483c4..7ecf496a9 100644
--- a/Command/PreCommit.hs
+++ b/Command/PreCommit.hs
@@ -20,7 +20,7 @@ def = [command "pre-commit" paramPaths seek "run by git pre-commit hook"]
seek :: [CommandSeek]
seek =
[ whenNotDirect $ withFilesToBeCommitted $ whenAnnexed $ Command.Fix.start
- , withFilesUnlockedToBeCommitted start]
+ , whenNotDirect $ withFilesUnlockedToBeCommitted start]
start :: FilePath -> CommandStart
start file = next $ perform file