From 82082e8b6f02f7fa003f8cf311122fa013ae641e Mon Sep 17 00:00:00 2001 From: stuebinm Date: Mon, 28 Mar 2022 17:07:03 +0200 Subject: server: show helpful information for result This includes the backlink to the lobby (auto-generated only for now) and a "help!"-button for sending mails. Also general info regarding which commit was linted / published. --- server/Server.hs | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'server/Server.hs') diff --git a/server/Server.hs b/server/Server.hs index 3081997..48a7170 100644 --- a/server/Server.hs +++ b/server/Server.hs @@ -92,13 +92,15 @@ toSha ref = Sha1 $ (show ref :: Text) data Org (loaded :: Bool) = Org - { orgSlug :: Text - , orgLintconfig :: ConfigRes loaded (LintConfig Skeleton) - , orgEntrypoint :: FilePath - , orgGeneration :: Int - , orgRepos :: [RemoteRef] - , orgUrl :: Text - , orgWebdir :: Text + { orgSlug :: Text + , orgLintconfig :: ConfigRes loaded (LintConfig Skeleton) + , orgEntrypoint :: FilePath + , orgGeneration :: Int + , orgRepos :: [RemoteRef] + , orgUrl :: Text + , orgWebdir :: Text + , orgBacklinkPrefix :: Text + , orgContactMail :: Text } deriving (Generic) instance NFData (LintConfig Skeleton) => NFData (Org True) @@ -160,6 +162,8 @@ orgCodec = Org <*> T.list remoteCodec "repo" .= orgRepos <*> T.text "url" .= orgUrl <*> T.text "webdir" .= orgWebdir + <*> T.text "backlink_prefix" .= orgBacklinkPrefix + <*> T.text "contact_mail" .= orgContactMail -- why exactly does everything in tomland need to be invertable urlBimap :: TomlBiMap BaseUrl String -- cgit v1.2.3