hit 0.2.1 → 0.2.2
raw patch · 2 files changed
+4/−5 lines, 2 filesdep −unix
Dependencies removed: unix
Files
- Data/Git/Loose.hs +3/−3
- hit.cabal +1/−2
Data/Git/Loose.hs view
@@ -34,7 +34,7 @@ import System.FilePath import System.Directory-import System.Posix.Files+import System.IO (openFile, hFileSize, IOMode(..)) import qualified Data.ByteString.Char8 as BC import qualified Data.ByteString.Lazy as L@@ -130,8 +130,8 @@ -- | create a new blob on a temporary location and on success move it to -- the object store with its digest name. looseWriteBlobFromFile repoPath file = do- fsz <- fromIntegral . fileSize <$> getFileStatus file- let hdr = objectWriteHeader TypeBlob fsz+ fsz <- openFile file ReadMode >>= hFileSize+ let hdr = objectWriteHeader TypeBlob (fromIntegral fsz) tmpPath <- objectTemporaryPath repoPath flip onException (removeFile tmpPath) $ do npath <- withFileWriter tmpPath $ \fw -> do
hit.cabal view
@@ -1,5 +1,5 @@ Name: hit-Version: 0.2.1+Version: 0.2.2 Synopsis: Git operations Description: Provides low level git operations License: BSD3@@ -40,7 +40,6 @@ , zlib , zlib-bindings >= 0.0.1 , bytedump- , unix Exposed-modules: Data.Git.Index Data.Git.Pack Data.Git.Object