add flags, and change to subcommand style
This commit is contained in:
parent
4c3ad80f32
commit
29039fdf97
7 changed files with 59 additions and 30 deletions
|
@ -12,10 +12,10 @@ import qualified GitRepo as Git
|
|||
|
||||
main = do
|
||||
args <- getArgs
|
||||
actions <- argvToActions args
|
||||
(flags, actions) <- parseCmd args
|
||||
gitrepo <- Git.repoFromCwd
|
||||
state <- new gitrepo
|
||||
tryRun state $ [setup] ++ actions ++ [shutdown]
|
||||
tryRun state $ [startup flags] ++ actions ++ [shutdown]
|
||||
|
||||
{- Runs a list of Annex actions. Catches exceptions, not stopping
|
||||
- if some error out, and propigates an overall error status at the end.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue