summaryrefslogtreecommitdiff
path: root/Command/Watch.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-06-08 00:29:39 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-06-08 00:29:39 -0400
commitd45a9a7831a567c548f2552e1470d72f1966fffd (patch)
tree172a41852cdc055f11606dbe5b68f7d0a7f91bc5 /Command/Watch.hs
parent7d78cbf97ca9d5a579f05b4ba735be69bafdef97 (diff)
refactor and function name cleanup
(oops, I had a calcMerge and a calc_merge!)
Diffstat (limited to 'Command/Watch.hs')
-rw-r--r--Command/Watch.hs12
1 files changed, 3 insertions, 9 deletions
diff --git a/Command/Watch.hs b/Command/Watch.hs
index bf544679d..c5d824864 100644
--- a/Command/Watch.hs
+++ b/Command/Watch.hs
@@ -19,9 +19,6 @@ import qualified Annex.Queue
import qualified Command.Add
import qualified Git.Command
import qualified Git.UpdateIndex
-import Git.HashObject
-import Git.Types
-import Git.FilePath
import qualified Backend
import Annex.Content
@@ -140,9 +137,6 @@ onErr = warning
{- Adds a symlink to the index, without ever accessing the actual symlink
- on disk. -}
stageSymlink :: FilePath -> String -> Annex ()
-stageSymlink file linktext = do
- line <- Git.UpdateIndex.update_index_line
- <$> inRepo (hashObject BlobObject linktext)
- <*> pure SymlinkBlob
- <*> inRepo (toTopFilePath file)
- Annex.Queue.addUpdateIndex $ \streamer -> streamer line
+stageSymlink file linktext =
+ Annex.Queue.addUpdateIndex =<<
+ inRepo (Git.UpdateIndex.stageSymlink file linktext)