summaryrefslogtreecommitdiff
path: root/src/wrapper.hs
diff options
context:
space:
mode:
authorJoey Hess2014-08-19 16:44:51 -0400
committerJoey Hess2014-08-19 16:44:51 -0400
commit4ae9578e3644cb3a11c105281b043721400f74cb (patch)
tree216a9c75405985215954367cffa7929521369c21 /src/wrapper.hs
parent3c61c109fbba19fb5c41870333f879fdc6dc0c1a (diff)
head file will end with a newline
Diffstat (limited to 'src/wrapper.hs')
-rw-r--r--src/wrapper.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wrapper.hs b/src/wrapper.hs
index 3c5c15d1..6912e204 100644
--- a/src/wrapper.hs
+++ b/src/wrapper.hs
@@ -22,6 +22,7 @@ import Utility.Exception
import Control.Monad
import Control.Monad.IfElse
+import Control.Applicative
import System.Directory
import System.FilePath
import System.Environment (getArgs)
@@ -73,7 +74,7 @@ wrapper args propellordir propellorbin = do
)
checkRepo = whenM (doesFileExist disthead) $ do
- headrev <- readFile disthead
+ headrev <- takeWhile (/= '\n') <$> readFile disthead
changeWorkingDirectory propellordir
headknown <- catchMaybeIO $
withQuietOutput createProcessSuccess $