summaryrefslogtreecommitdiff
path: root/Git/CatFile.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Git/CatFile.hs')
-rwxr-xr-x[-rw-r--r--]Git/CatFile.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Git/CatFile.hs b/Git/CatFile.hs
index b83241445..5ab10b187 100644..100755
--- a/Git/CatFile.hs
+++ b/Git/CatFile.hs
@@ -23,6 +23,7 @@ import Git
import Git.Sha
import Git.Command
import Git.Types
+import Git.FilePath
import qualified Utility.CoProcess as CoProcess
type CatFileHandle = CoProcess.CoProcessHandle
@@ -38,7 +39,8 @@ catFileStop = CoProcess.stop
{- Reads a file from a specified branch. -}
catFile :: CatFileHandle -> Branch -> FilePath -> IO L.ByteString
-catFile h branch file = catObject h $ Ref $ show branch ++ ":" ++ file
+catFile h branch file = catObject h $ Ref $
+ show branch ++ ":" ++ toInternalGitPath file
{- Uses a running git cat-file read the content of an object.
- Objects that do not exist will have "" returned. -}