random hlint (to give the autobuilder something new to build)
This commit is contained in:
parent
b914620264
commit
2d480602aa
6 changed files with 12 additions and 14 deletions
|
@ -243,10 +243,9 @@ finishGetViaTmp check key action = do
|
||||||
moveAnnex key tmpfile
|
moveAnnex key tmpfile
|
||||||
logStatus key InfoPresent
|
logStatus key InfoPresent
|
||||||
return True
|
return True
|
||||||
, do
|
-- the tmp file is left behind, in case caller wants
|
||||||
-- the tmp file is left behind, in case caller wants
|
-- to resume its transfer
|
||||||
-- to resume its transfer
|
, return False
|
||||||
return False
|
|
||||||
)
|
)
|
||||||
|
|
||||||
prepTmp :: Key -> Annex FilePath
|
prepTmp :: Key -> Annex FilePath
|
||||||
|
|
|
@ -66,7 +66,7 @@ changeAssociatedFiles key transform = do
|
||||||
mapping <- calcRepo $ gitAnnexMapping key
|
mapping <- calcRepo $ gitAnnexMapping key
|
||||||
files <- associatedFilesRelative key
|
files <- associatedFilesRelative key
|
||||||
let files' = transform files
|
let files' = transform files
|
||||||
when (files /= files') $ do
|
when (files /= files') $
|
||||||
modifyContent mapping $
|
modifyContent mapping $
|
||||||
liftIO $ viaTmp writeFileAnyEncoding mapping $
|
liftIO $ viaTmp writeFileAnyEncoding mapping $
|
||||||
unlines files'
|
unlines files'
|
||||||
|
|
|
@ -184,7 +184,7 @@ mergeDirectCleanup d oldsha newsha = do
|
||||||
tryAnnex . maybe (araw f item) (\k -> void $ a k f)
|
tryAnnex . maybe (araw f item) (\k -> void $ a k f)
|
||||||
=<< catKey (getsha item) (getmode item)
|
=<< catKey (getsha item) (getmode item)
|
||||||
|
|
||||||
moveout k f = removeDirect k f
|
moveout = removeDirect
|
||||||
|
|
||||||
{- Files deleted by the merge are removed from the work tree.
|
{- Files deleted by the merge are removed from the work tree.
|
||||||
- Empty work tree directories are removed, per git behavior. -}
|
- Empty work tree directories are removed, per git behavior. -}
|
||||||
|
|
|
@ -43,7 +43,7 @@ checkMatcher matcher mkey afile notpresent def
|
||||||
fileMatchInfo :: FilePath -> Annex MatchInfo
|
fileMatchInfo :: FilePath -> Annex MatchInfo
|
||||||
fileMatchInfo file = do
|
fileMatchInfo file = do
|
||||||
matchfile <- getTopFilePath <$> inRepo (toTopFilePath file)
|
matchfile <- getTopFilePath <$> inRepo (toTopFilePath file)
|
||||||
return $ MatchingFile $ FileInfo
|
return $ MatchingFile FileInfo
|
||||||
{ matchFile = matchfile
|
{ matchFile = matchfile
|
||||||
, relFile = file
|
, relFile = file
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,11 +70,10 @@ initialize mdescription = do
|
||||||
( do
|
( do
|
||||||
enableDirectMode
|
enableDirectMode
|
||||||
setDirect True
|
setDirect True
|
||||||
, do
|
-- Handle case where this repo was cloned from a
|
||||||
-- Handle case where this repo was cloned from a
|
-- direct mode repo
|
||||||
-- direct mode repo.
|
, unlessM isBare
|
||||||
unlessM isBare
|
switchHEADBack
|
||||||
switchHEADBack
|
|
||||||
)
|
)
|
||||||
createInodeSentinalFile
|
createInodeSentinalFile
|
||||||
u <- getUUID
|
u <- getUUID
|
||||||
|
@ -227,7 +226,7 @@ fixBadBare = whenM checkBadBare $ do
|
||||||
logStatus k InfoPresent
|
logStatus k InfoPresent
|
||||||
let dotgit = d </> ".git"
|
let dotgit = d </> ".git"
|
||||||
liftIO $ removeDirectoryRecursive dotgit
|
liftIO $ removeDirectoryRecursive dotgit
|
||||||
`catchIO` (const $ renameDirectory dotgit (d </> "removeme"))
|
`catchIO` const (renameDirectory dotgit (d </> "removeme"))
|
||||||
|
|
||||||
{- A repostory with the problem won't know it's a bare repository, but will
|
{- A repostory with the problem won't know it's a bare repository, but will
|
||||||
- have no pre-commit hook (which is not set up in a bare repository),
|
- have no pre-commit hook (which is not set up in a bare repository),
|
||||||
|
|
|
@ -76,7 +76,7 @@ bestSocketPath abssocketfile = do
|
||||||
-- ssh appends a 16 char extension to the socket when setting it
|
-- ssh appends a 16 char extension to the socket when setting it
|
||||||
-- up, which needs to be taken into account when checking
|
-- up, which needs to be taken into account when checking
|
||||||
-- that a valid socket was constructed.
|
-- that a valid socket was constructed.
|
||||||
sshgarbage = take (1+16) $ repeat 'X'
|
sshgarbage = replicate (1+16) 'X'
|
||||||
|
|
||||||
sshConnectionCachingParams :: FilePath -> [CommandParam]
|
sshConnectionCachingParams :: FilePath -> [CommandParam]
|
||||||
sshConnectionCachingParams socketfile =
|
sshConnectionCachingParams socketfile =
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue