diff options
author | Jasper Van der Jeugt | 2020-08-13 19:19:22 +0200 |
---|---|---|
committer | Jasper Van der Jeugt | 2020-08-13 19:19:22 +0200 |
commit | 8d5c0405565ad4afd976efd1262b3224efd6ee2f (patch) | |
tree | 8d24ecb97212d54943d104ed95f1fda4dea7c1fd /server/lib/Uplcg/Main | |
parent | a39fe7ff759a552c64a060f0d98a0d4e8a577b01 (diff) |
cafp -> uplcg
Diffstat (limited to '')
-rw-r--r-- | server/lib/Uplcg/Main/GenerateElmTypes.hs (renamed from server/lib/Cafp/Main/GenerateElmTypes.hs) | 4 | ||||
-rw-r--r-- | server/lib/Uplcg/Main/Server.hs (renamed from server/lib/Cafp/Main/Server.hs) | 16 |
2 files changed, 10 insertions, 10 deletions
diff --git a/server/lib/Cafp/Main/GenerateElmTypes.hs b/server/lib/Uplcg/Main/GenerateElmTypes.hs index ccf19e8..bc2481c 100644 --- a/server/lib/Cafp/Main/GenerateElmTypes.hs +++ b/server/lib/Uplcg/Main/GenerateElmTypes.hs @@ -1,10 +1,10 @@ {-# OPTIONS_GHC -fno-warn-orphans #-} {-# LANGUAGE TemplateHaskell #-} -module Cafp.Main.GenerateElmTypes +module Uplcg.Main.GenerateElmTypes ( main ) where -import Cafp.Messages +import Uplcg.Messages import Data.Proxy import Elm.Module diff --git a/server/lib/Cafp/Main/Server.hs b/server/lib/Uplcg/Main/Server.hs index ba2425d..a2914ab 100644 --- a/server/lib/Cafp/Main/Server.hs +++ b/server/lib/Uplcg/Main/Server.hs @@ -1,17 +1,14 @@ {-# LANGUAGE OverloadedStrings #-} -module Cafp.Main.Server +module Uplcg.Main.Server ( main ) where -import qualified Cafp.CookieSocket as CookieSocket -import Cafp.Game -import Cafp.Messages import Control.Concurrent.MVar (MVar) import qualified Control.Concurrent.MVar as MVar import Control.Concurrent.STM (STM, TVar, atomically) import qualified Control.Concurrent.STM as STM import Control.Exception (bracket) -import Control.Lens ((^.), (&), (.~)) +import Control.Lens ((&), (.~), (^.)) import Control.Monad (forever, when) import qualified Data.Aeson as Aeson import qualified Data.ByteString as B @@ -33,6 +30,9 @@ import qualified Network.WebSockets as WS import System.Environment (getEnv) import qualified System.Log.FastLogger as FL import System.Random (StdGen, newStdGen) +import qualified Uplcg.CookieSocket as CookieSocket +import Uplcg.Game +import Uplcg.Messages import qualified Web.Scotty as Scotty type RoomId = T.Text @@ -200,9 +200,9 @@ baseUrl prefix application = \req -> main :: IO () main = do - host <- fromString <$> getEnv "CAFP_HOSTNAME" - port <- read <$> getEnv "CAFP_PORT" - base <- splitPath . T.pack <$> getEnv "CAFP_BASE" + host <- fromString <$> getEnv "UPLCG_HOSTNAME" + port <- read <$> getEnv "UPLCG_PORT" + base <- splitPath . T.pack <$> getEnv "UPLCG_BASE" let settings = Warp.setPort port . Warp.setHost host $ Warp.defaultSettings timeCache <- FL.newTimeCache FL.simpleTimeFormat FL.withTimedFastLogger timeCache |