My favorites | Sign in
Project Home
New issue   Search
for
  Advanced search   Search tips   Subscriptions

Issue 115 attachment: strictRunShellCommand.patch (3.3 KB)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
1 patch for repository http://johnmacfarlane.net/repos/filestore:

Mon Apr 18 12:01:45 Eastern Daylight Time 2011 fryguybob@gmail.com
* Switch to using strict bytestring to read captured output in runShellCommand.

New patches:

[Switch to using strict bytestring to read captured output in runShellCommand.
fryguybob@gmail.com**20110418160145
Ignore-this: 4593a64e0e45560c68b57a5e1fa95748
] hunk ./Data/FileStore/Utils.hs 41
import System.IO (openTempFile, hClose)
import System.Process (runProcess, waitForProcess)
import qualified Data.ByteString.Lazy as B
+import qualified Data.ByteString as S

import Data.FileStore.Types (SearchMatch(..), FileStoreError(IllegalResourceName, NotFound, UnknownError), SearchQuery(..))

hunk ./Data/FileStore/Utils.hs 58
(errorPath, hErr) <- openTempFile tempPath "err"
hProcess <- runProcess (encodeString command) (map encodeString optionList) (Just workingDir) environment Nothing (Just hOut) (Just hErr)
status <- waitForProcess hProcess
- errorOutput <- B.readFile errorPath
- output <- B.readFile outputPath
+ errorOutput <- S.readFile errorPath
+ output <- S.readFile outputPath
removeFile errorPath
removeFile outputPath
hunk ./Data/FileStore/Utils.hs 62
- return (status, errorOutput, output)
+ return (status, B.fromChunks [errorOutput], B.fromChunks [output])

-- | Do a three way merge, using either git merge-file or RCS merge. Assumes
-- that either @git@ or @merge@ is in the system path. Assumes UTF-8 locale.

Context:

[Darcs didn't retrieve old revisions of file who currently do not exist
FĂ©lix Lequen <flequen@gmail.com>**20110221094413
Ignore-this: 1297dcfde17752c95aec53ba77c07436
]
[Added test for retrieving deleted file
jgm@berkeley.edu**20110221014125
Ignore-this: e654e2eca96501b4178ceec616e942f3
]
[TAG 0.4.0.3
jgm@berkeley.edu**20110128061350
Ignore-this: cb75f77bfeed7c3f799e49d0d6ff50ed
]
[Version bump to 0.4.0.3.
jgm@berkeley.edu**20110127164607
Ignore-this: b5510025d9889ad81974cdc9c5e2fb40
]
[Increased upper bound for time package.
jgm@berkeley.edu**20110127164547
Ignore-this: a4a3c415f172fdfdd64aed8a9bad0ad
]
[Changed isInsideDir so it doesn't use canonicalizePath.
jgm@berkeley.edu**20110126162834
Ignore-this: 5a908fbc8b1c2835f84a0a5310a0009c

In directory-1.1.0.0 (ghc7), canonicalizePath was changed so
that it fails if the directory does not exist. We need this
test not to presuppose that the directory exists. So instead,
we do a simple prefix comparison, returning False if either the filename
or the directory name contains '..'.
]
[Utils: Don't export isInsideDir.
jgm@berkeley.edu**20110126162745
Ignore-this: 69a6b1f82d7c2a3a7ad12abacd35fcaf
]
[Bump version to 0.4.0.2.
jgm@berkeley.edu**20110126153910
Ignore-this: f6b9e96eecab42b122b9e6a464743f47
]
[Relaxed filepath constraints.
jgm@berkeley.edu**20110126081216
Ignore-this: 105e0e202fe62e3acd6f062b8aa0a04d
]
[Relaxed package bounds for ghc 7.
jgm@berkeley.edu**20110126074506
Ignore-this: dad9b88a895f1f39abbecf2aa95eb2e9
]
[TAG 0.4.0.1
jgm@berkeley.edu**20110125042516
Ignore-this: 6678997ed7dc71c8466bd211d5081957
]
[Bump version to 0.4.0.1
jgm@berkeley.edu**20110125042505
Ignore-this: e6523da0b75a18a28ab2aa8534249a53
]
[TAG 0.4
jgm@berkeley.edu**20110125041936
Ignore-this: 513d4c018592619405a8113ecf9276da
]
Patch bundle hash:
bf6d8f039a5afd2a8b27969348abdb3f75e32d6e
Powered by Google Project Hosting