Use new optparse-applicative and bcrypt

Fixes #131 and affects #129
This commit is contained in:
Joe Nelson
2015-02-07 14:21:40 -08:00
parent 3662c1d428
commit d77b6df851
3 changed files with 25 additions and 19 deletions
+8 -2
View File
@@ -24,7 +24,14 @@ import Config (AppConfig(..), argParser, corsPolicy)
main :: IO ()
main = do
conf <- execParser (info (helper <*> argParser) describe)
let opts = info (helper <*> argParser) $
fullDesc
<> progDesc (
"PostgREST "
<> prettyVersion
<> " / create a REST API to an existing Postgres database"
)
conf <- execParser opts
let port = configPort conf
unless (configSecure conf) $
@@ -59,5 +66,4 @@ main = do
either (respond . errResponse) respond resOrError
where
describe = progDesc "create a REST API to an existing Postgres database"
prettyVersion = intercalate "." $ map show $ versionBranch version