reorganize some files and imports

This commit is contained in:
Joey Hess 2014-01-26 16:25:55 -04:00
parent 3149a62a35
commit 86ffeb73d1
34 changed files with 92 additions and 120 deletions

View file

@ -24,7 +24,6 @@ import qualified Annex.Branch
import qualified Git
import Git.Command
import qualified Remote
import qualified Option
import qualified Annex
data RefChange = RefChange
@ -44,14 +43,14 @@ options = passthruOptions ++ [gourceOption]
passthruOptions :: [Option]
passthruOptions = map odate ["since", "after", "until", "before"] ++
[ Option.field ['n'] "max-count" paramNumber
[ fieldOption ['n'] "max-count" paramNumber
"limit number of logs displayed"
]
where
odate n = Option.field [] n paramDate $ "show log " ++ n ++ " date"
odate n = fieldOption [] n paramDate $ "show log " ++ n ++ " date"
gourceOption :: Option
gourceOption = Option.flag [] "gource" "format output for gource"
gourceOption = flagOption [] "gource" "format output for gource"
seek :: CommandSeek
seek ps = do
@ -62,8 +61,8 @@ seek ps = do
withFilesInGit (whenAnnexed $ start m zone os gource) ps
where
getoption o = maybe [] (use o) <$>
Annex.getField (Option.name o)
use o v = [Param ("--" ++ Option.name o), Param v]
Annex.getField (optionName o)
use o v = [Param ("--" ++ optionName o), Param v]
start :: M.Map UUID String -> TimeZone -> [CommandParam] -> Bool ->
FilePath -> (Key, Backend) -> CommandStart