From 9bce151df7b073c5f2507ea15ca2237814ae9248 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 3 Mar 2013 13:39:07 -0400 Subject: git subcommand cleanup Pass subcommand as a regular param, which allows passing git parameters like -c before it. This was already done in the pipeing set of functions, but not the command running set. --- Upgrade/V2.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Upgrade') diff --git a/Upgrade/V2.hs b/Upgrade/V2.hs index beddc5b8b..935fc4825 100644 --- a/Upgrade/V2.hs +++ b/Upgrade/V2.hs @@ -54,7 +54,7 @@ upgrade = do showProgress when e $ do - inRepo $ Git.Command.run "rm" [Param "-r", Param "-f", Param "-q", File old] + inRepo $ Git.Command.run [Param "rm", Param "-r", Param "-f", Param "-q", File old] unless bare $ inRepo gitAttributesUnWrite showProgress @@ -105,8 +105,8 @@ push = do Annex.Branch.update -- just in case showAction "pushing new git-annex branch to origin" showOutput - inRepo $ Git.Command.run "push" - [Param "origin", Param $ show Annex.Branch.name] + inRepo $ Git.Command.run + [Param "push", Param "origin", Param $ show Annex.Branch.name] _ -> do -- no origin exists, so just let the user -- know about the new branch @@ -129,7 +129,7 @@ gitAttributesUnWrite repo = do c <- readFileStrict attributes liftIO $ viaTmp writeFile attributes $ unlines $ filter (`notElem` attrLines) $ lines c - Git.Command.run "add" [File attributes] repo + Git.Command.run [Param "add", File attributes] repo stateDir :: FilePath stateDir = addTrailingPathSeparator ".git-annex" -- cgit v1.2.3