format all the things

This commit is contained in:
Lucy Cifferello
2021-09-23 19:18:25 -06:00
committed by Keagan McClelland
parent ac5acaa685
commit e2d2fb6afc
24 changed files with 604 additions and 515 deletions

View File

@@ -6,7 +6,7 @@
module Handler.Version where
import Startlude hiding (Handler)
import Startlude hiding ( Handler )
import Control.Monad.Trans.Maybe
import Yesod.Core
@@ -28,10 +28,10 @@ getVersionR = do
getVersionAppR :: Text -> Handler (Maybe AppVersionRes)
getVersionAppR appId = do
(appsDir, appMgrDir) <- getsYesod $ ((</> "apps") . resourcesDir &&& staticBinDir) . appSettings
res <- getVersionWSpec appsDir appExt
res <- getVersionWSpec appsDir appExt
case res of
Nothing -> pure res
Just r -> do
Just r -> do
let appDir = (<> "/") . (</> (show $ appVersionVersion r)) . (</> toS appId) $ appsDir
addPackageHeader appMgrDir appDir appExt
pure res
@@ -50,4 +50,4 @@ getVersionSysR sysAppId = runMaybeT $ do
getVersionWSpec :: KnownSymbol a => FilePath -> Extension a -> Handler (Maybe AppVersionRes)
getVersionWSpec rootDir ext = do
av <- getVersionFromQuery rootDir ext
pure $ liftA3 AppVersionRes av (pure Nothing) (pure Nothing)
pure $ liftA3 AppVersionRes av (pure Nothing) (pure Nothing)