diff options
author | Joey Hess <joey@kitenet.net> | 2011-09-29 23:43:42 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2011-09-29 23:48:57 -0400 |
commit | 7ff89ccfee13dcfe89cbdef83454e880dabd7186 (patch) | |
tree | 953858f36ccd021832d286c6a5915e44a05081ce /Git/LsTree.hs | |
parent | 949ef94d5e5583e55d6ba9797cf71177b252173d (diff) |
convert all git read/write functions to use ByteStrings
This yields a second or so speedup in unused, find, etc. Seems that even
when the ByteString is immediately split and then converted to Strings,
it's faster.
I may try to push ByteStrings out into more of git-annex gradually,
although I suspect most of the time-critical parts are already covered
now, and many of the rest rely on libraries that only support Strings.
Diffstat (limited to 'Git/LsTree.hs')
-rw-r--r-- | Git/LsTree.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Git/LsTree.hs b/Git/LsTree.hs index e0aa5a443..c072ef5be 100644 --- a/Git/LsTree.hs +++ b/Git/LsTree.hs @@ -16,7 +16,7 @@ import Control.Applicative import System.Posix.Types import qualified Data.ByteString.Lazy.Char8 as L -import Git.ByteString +import Git import Utility.SafeCommand type Treeish = String @@ -31,7 +31,7 @@ data TreeItem = TreeItem {- Lists the contents of a Treeish -} lsTree :: Repo -> Treeish -> IO [TreeItem] lsTree repo t = map parseLsTree <$> - pipeNullSplit repo [Params "ls-tree --full-tree -z -r --", File t] + pipeNullSplitB repo [Params "ls-tree --full-tree -z -r --", File t] {- Parses a line of ls-tree output. - (The --long format is not currently supported.) -} |