summaryrefslogtreecommitdiff
path: root/Git
diff options
context:
space:
mode:
authorJoey Hess <joeyh@joeyh.name>2023-02-27 15:02:53 -0400
committerJoey Hess <joeyh@joeyh.name>2023-02-27 15:06:32 -0400
commitf09e299156fa01e4591fa3695c4f2bc827fe3db0 (patch)
tree22d331240b67fc0437689b2514901784da703d39 /Git
parentcc32e31161a27b0eb2adb6a832f3d1e843cdf98b (diff)
rawfilepath conversion
Diffstat (limited to 'Git')
-rw-r--r--Git/Repair.hs2
-rw-r--r--Git/UpdateIndex.hs8
2 files changed, 5 insertions, 5 deletions
diff --git a/Git/Repair.hs b/Git/Repair.hs
index 3b51ff1479..601b32291a 100644
--- a/Git/Repair.hs
+++ b/Git/Repair.hs
@@ -433,7 +433,7 @@ rewriteIndex r
reinject (file, sha, mode, _) = case toTreeItemType mode of
Nothing -> return Nothing
Just treeitemtype -> Just <$>
- UpdateIndex.stageFile sha treeitemtype (fromRawFilePath file) r
+ UpdateIndex.stageFile sha treeitemtype file r
newtype GoodCommits = GoodCommits (S.Set Sha)
diff --git a/Git/UpdateIndex.hs b/Git/UpdateIndex.hs
index 0ac21617fb..f56bc86cbc 100644
--- a/Git/UpdateIndex.hs
+++ b/Git/UpdateIndex.hs
@@ -99,15 +99,15 @@ updateIndexLine sha treeitemtype file = L.fromStrict $
<> "\t"
<> indexPath file
-stageFile :: Sha -> TreeItemType -> FilePath -> Repo -> IO Streamer
+stageFile :: Sha -> TreeItemType -> RawFilePath -> Repo -> IO Streamer
stageFile sha treeitemtype file repo = do
- p <- toTopFilePath (toRawFilePath file) repo
+ p <- toTopFilePath file repo
return $ pureStreamer $ updateIndexLine sha treeitemtype p
{- A streamer that removes a file from the index. -}
-unstageFile :: FilePath -> Repo -> IO Streamer
+unstageFile :: RawFilePath -> Repo -> IO Streamer
unstageFile file repo = do
- p <- toTopFilePath (toRawFilePath file) repo
+ p <- toTopFilePath file repo
return $ unstageFile' p
unstageFile' :: TopFilePath -> Streamer