add GalleryInfo
This commit is contained in:
parent
2844df96cd
commit
ae5dc6b006
2 changed files with 60 additions and 14 deletions
|
@ -31,20 +31,6 @@ data ModeOptions =
|
|||
}
|
||||
deriving Show
|
||||
|
||||
data Who = Mine | NotMine | All deriving (Eq, Show)
|
||||
|
||||
|
||||
readWho :: String -> Maybe Who
|
||||
readWho "mine" = Just Mine
|
||||
readWho "not-mine" = Just NotMine
|
||||
readWho "all" = Just All
|
||||
readWho _ = Nothing
|
||||
|
||||
matchWho :: Who -> Info -> Bool
|
||||
matchWho Mine = #mine
|
||||
matchWho NotMine = #notMine
|
||||
matchWho _ = const True
|
||||
|
||||
|
||||
optionsParser :: ParserInfo Options
|
||||
optionsParser = globalOpts `info` mainInfo where
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue