summaryrefslogtreecommitdiff
path: root/Command/Init.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2011-06-30 00:42:09 -0400
committerGravatar Joey Hess <joey@kitenet.net>2011-06-30 00:46:39 -0400
commit2cda9d0a0fcdd1cc2aebc066ef19282fbe36e898 (patch)
treede4244439c340a664afd2993b7203ca8ac31e0cd /Command/Init.hs
parentd72fb5acc28af3ea6380dd09518f7d1382dea8d2 (diff)
generalized safeWriteFile to viaTmp
Diffstat (limited to 'Command/Init.hs')
-rw-r--r--Command/Init.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Command/Init.hs b/Command/Init.hs
index 7f5773117..8cde8bb9f 100644
--- a/Command/Init.hs
+++ b/Command/Init.hs
@@ -55,7 +55,7 @@ gitPreCommitHookWrite repo = do
if exists
then warning $ "pre-commit hook (" ++ hook ++ ") already exists, not configuring"
else liftIO $ do
- safeWriteFile hook preCommitScript
+ viaTmp writeFile hook preCommitScript
p <- getPermissions hook
setPermissions hook $ p {executable = True}
where