git-annex/Command/Upgrade.hs
Joey Hess fa3045aa8b make "git annex help options" work outside a git repo
Option parsing for commands that run outside git repos is still screwy,
as there is no Annex monad and so the flags cannot be passed in. But,
any remaining parameters can be, which is enough for this fix.
2013-11-30 15:18:40 -04:00

26 lines
546 B
Haskell

{- git-annex command
-
- Copyright 2011 Joey Hess <joey@kitenet.net>
-
- Licensed under the GNU GPL version 3 or higher.
-}
module Command.Upgrade where
import Common.Annex
import Command
import Upgrade
def :: [Command]
def = [dontCheck repoExists $ -- because an old version may not seem to exist
command "upgrade" paramNothing seek
SectionMaintenance "upgrade repository layout"]
seek :: [CommandSeek]
seek = [withNothing start]
start :: CommandStart
start = do
showStart "upgrade" "."
r <- upgrade False
next $ next $ return r