upped lts-version, updated libs, fixed broken stuff
This commit is contained in:
parent
80920116cd
commit
370ce9ded5
@ -125,7 +125,7 @@ getApplicationDev = do
|
|||||||
return (wsettings, app)
|
return (wsettings, app)
|
||||||
|
|
||||||
getAppSettings :: IO AppSettings
|
getAppSettings :: IO AppSettings
|
||||||
getAppSettings = loadAppSettings [configSettingsYml] [] useEnv
|
getAppSettings = loadYamlSettings [configSettingsYml] [] useEnv
|
||||||
|
|
||||||
-- | main function for use by yesod devel
|
-- | main function for use by yesod devel
|
||||||
develMain :: IO ()
|
develMain :: IO ()
|
||||||
@ -135,7 +135,7 @@ develMain = develMainHelper getApplicationDev
|
|||||||
appMain :: IO ()
|
appMain :: IO ()
|
||||||
appMain = do
|
appMain = do
|
||||||
-- Get the settings from all relevant sources
|
-- Get the settings from all relevant sources
|
||||||
settings <- loadAppSettingsArgs
|
settings <- loadYamlSettingsArgs
|
||||||
-- fall back to compile-time values, set to [] to require values at runtime
|
-- fall back to compile-time values, set to [] to require values at runtime
|
||||||
[configSettingsYmlValue]
|
[configSettingsYmlValue]
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ import Yesod.Default.Util (addStaticContentExternal)
|
|||||||
import Yesod.Core.Types (Logger)
|
import Yesod.Core.Types (Logger)
|
||||||
import qualified Yesod.Core.Unsafe as Unsafe
|
import qualified Yesod.Core.Unsafe as Unsafe
|
||||||
--import Yesod.Auth.HashDB (authHashDB)
|
--import Yesod.Auth.HashDB (authHashDB)
|
||||||
import Yesod.Auth.OAuth2.EveOnline (oauth2Eve,WidgetType(..))
|
import Yesod.Auth.OAuth2.EveOnline (oauth2EveScoped,WidgetType(..))
|
||||||
import Data.Time.Format (parseTimeM)
|
import Data.Time.Format (parseTimeM)
|
||||||
|
|
||||||
-- | The foundation datatype for your application. This can be a good place to
|
-- | The foundation datatype for your application. This can be a good place to
|
||||||
@ -179,11 +179,64 @@ instance YesodAuth App where
|
|||||||
-- You can add other plugins like BrowserID, email or OAuth here
|
-- You can add other plugins like BrowserID, email or OAuth here
|
||||||
authPlugins _ = [ --authBrowserId def
|
authPlugins _ = [ --authBrowserId def
|
||||||
--, authHashDB (Just . UniqueUser)
|
--, authHashDB (Just . UniqueUser)
|
||||||
oauth2Eve "346ee0ad8f974e30be6bf422f40d891b" "kXnZd7f3pmRCvePiBPQcTL2aRcgBHSgPRxc6VNYT" BigBlack
|
oauth2EveScoped "346ee0ad8f974e30be6bf422f40d891b" "kXnZd7f3pmRCvePiBPQcTL2aRcgBHSgPRxc6VNYT"
|
||||||
|
[ "publicData"
|
||||||
|
, "characterContactsRead"
|
||||||
|
, "characterLocationRead"
|
||||||
|
, "characterWalletRead"
|
||||||
|
, "characterAssetsRead"
|
||||||
|
, "characterIndustryJobsRead"
|
||||||
|
, "characterMarketOrdersRead"
|
||||||
|
, "characterResearchRead"
|
||||||
|
, "characterAccountRead"
|
||||||
|
, "characterContractsRead"
|
||||||
|
, "characterClonesRead"
|
||||||
|
, "characterLoyaltyPointsRead"
|
||||||
|
, "corporationWalletRead"
|
||||||
|
, "corporationAssetsRead"
|
||||||
|
, "corporationIndustryJobsRead"
|
||||||
|
, "corporationMarketOrdersRead"
|
||||||
|
, "corporationStructuresRead"
|
||||||
|
, "remoteClientUI"
|
||||||
|
, "esi-location.read_location.v1"
|
||||||
|
, "esi-skills.read_skills.v1"
|
||||||
|
, "esi-wallet.read_character_wallet.v1"
|
||||||
|
, "esi-wallet.read_corporation_wallet.v1"
|
||||||
|
, "esi-search.search_structures.v1"
|
||||||
|
, "esi-clones.read_clones.v1"
|
||||||
|
, "esi-universe.read_structures.v1"
|
||||||
|
, "esi-assets.read_assets.v1"
|
||||||
|
, "esi-planets.manage_planets.v1"
|
||||||
|
, "esi-ui.open_window.v1"
|
||||||
|
, "esi-ui.write_waypoint.v1"
|
||||||
|
, "esi-markets.structure_markets.v1"
|
||||||
|
, "esi-corporations.read_structures.v1"
|
||||||
|
, "esi-corporations.write_structures.v1"
|
||||||
|
, "esi-characters.read_standings.v1"
|
||||||
|
, "esi-industry.read_character_jobs.v1"
|
||||||
|
, "esi-markets.read_character_orders.v1"
|
||||||
|
, "esi-contracts.read_character_contracts.v1"
|
||||||
|
, "esi-clones.read_implants.v1"
|
||||||
|
, "esi-corporations.track_members.v1"
|
||||||
|
, "esi-wallet.read_corporation_wallets.v1"
|
||||||
|
, "esi-assets.read_corporation_assets.v1"
|
||||||
|
, "esi-corporations.read_blueprints.v1"
|
||||||
|
, "esi-contracts.read_corporation_contracts.v1"
|
||||||
|
, "esi-corporations.read_standings.v1"
|
||||||
|
, "esi-corporations.read_starbases.v1"
|
||||||
|
, "esi-industry.read_corporation_jobs.v1"
|
||||||
|
, "esi-corporations.read_container_logs.v1"
|
||||||
|
, "esi-industry.read_character_mining.v1"
|
||||||
|
, "esi-industry.read_corporation_mining.v1"
|
||||||
|
, "esi-planets.read_customs_offices.v1"
|
||||||
|
, "esi-corporations.read_outposts.v1"
|
||||||
|
]
|
||||||
|
widget
|
||||||
]
|
]
|
||||||
|
where
|
||||||
|
widget = [whamlet|<img src="https://images.contentful.com/idjq7aai9ylm/4fSjj56uD6CYwYyus4KmES/4f6385c91e6de56274d99496e6adebab/EVE_SSO_Login_Buttons_Large_Black.png?w=270&h=45">|]
|
||||||
|
|
||||||
authHttpManager = getHttpManager
|
authHttpManager = getHttpManager
|
||||||
|
|
||||||
instance YesodAuthPersist App
|
instance YesodAuthPersist App
|
||||||
|
|
||||||
-- This instance is required to use forms. You can modify renderMessage to
|
-- This instance is required to use forms. You can modify renderMessage to
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
module Settings where
|
module Settings where
|
||||||
|
|
||||||
import ClassyPrelude.Yesod
|
import ClassyPrelude.Yesod
|
||||||
import Control.Exception (throw)
|
import Control.Exception as Ex (throw)
|
||||||
import Data.Aeson (Result (..), fromJSON, withObject, (.!=),
|
import Data.Aeson (Result (..), fromJSON, withObject, (.!=),
|
||||||
(.:?))
|
(.:?))
|
||||||
import Data.FileEmbed (embedFile)
|
import Data.FileEmbed (embedFile)
|
||||||
@ -108,7 +108,7 @@ configSettingsYmlBS = $(embedFile configSettingsYml)
|
|||||||
|
|
||||||
-- | @config/settings.yml@, parsed to a @Value@.
|
-- | @config/settings.yml@, parsed to a @Value@.
|
||||||
configSettingsYmlValue :: Value
|
configSettingsYmlValue :: Value
|
||||||
configSettingsYmlValue = either throw id $ decodeEither' configSettingsYmlBS
|
configSettingsYmlValue = either Ex.throw id $ decodeEither' configSettingsYmlBS
|
||||||
|
|
||||||
-- | A version of @AppSettings@ parsed at compile time from @config/settings.yml@.
|
-- | A version of @AppSettings@ parsed at compile time from @config/settings.yml@.
|
||||||
compileTimeAppSettings :: AppSettings
|
compileTimeAppSettings :: AppSettings
|
||||||
|
58
neat.cabal
58
neat.cabal
@ -65,37 +65,37 @@ library
|
|||||||
TupleSections
|
TupleSections
|
||||||
RecordWildCards
|
RecordWildCards
|
||||||
|
|
||||||
build-depends: base >= 4 && < 5
|
build-depends: base
|
||||||
, yesod >= 1.4.1 && < 1.6
|
, yesod
|
||||||
, yesod-core >= 1.4.6 && < 1.6
|
, yesod-core
|
||||||
, yesod-auth >= 1.4.4 && < 1.6
|
, yesod-auth
|
||||||
, yesod-static >= 1.4.0.3 && < 1.6
|
, yesod-static
|
||||||
, yesod-form >= 1.4.0 && < 1.6
|
, yesod-form
|
||||||
, yesod-auth-hashdb >= 1.4.0 && < 1.6
|
, yesod-auth-hashdb
|
||||||
, yesod-auth-oauth2 >= 0.1.2
|
, yesod-auth-oauth2
|
||||||
, classy-prelude >= 0.10.2
|
, classy-prelude
|
||||||
, classy-prelude-conduit >= 0.10.2
|
, classy-prelude-conduit
|
||||||
, classy-prelude-yesod >= 0.10.2
|
, classy-prelude-yesod
|
||||||
, bytestring >= 0.9 && < 0.11
|
, bytestring
|
||||||
, text >= 0.11 && < 2.0
|
, text
|
||||||
, persistent >= 2.0 && < 2.3
|
, persistent
|
||||||
, persistent-postgresql >= 2.1.1 && < 2.3
|
, persistent-postgresql
|
||||||
, persistent-template >= 2.0 && < 2.3
|
, persistent-template
|
||||||
, template-haskell
|
, template-haskell
|
||||||
, shakespeare >= 2.0 && < 2.1
|
, shakespeare
|
||||||
, hjsmin >= 0.1 && < 0.2
|
, hjsmin
|
||||||
, monad-control >= 0.3 && < 1.1
|
, monad-control
|
||||||
, wai-extra >= 3.0 && < 3.1
|
, wai-extra
|
||||||
, yaml >= 0.8 && < 0.9
|
, yaml
|
||||||
, http-conduit >= 2.1 && < 2.2
|
, http-conduit
|
||||||
, directory >= 1.1 && < 1.3
|
, directory
|
||||||
, warp >= 3.0 && < 3.2
|
, warp
|
||||||
, data-default
|
, data-default
|
||||||
, aeson >= 0.6
|
, aeson
|
||||||
, conduit >= 1.0 && < 2.0
|
, conduit
|
||||||
, monad-logger >= 0.3 && < 0.4
|
, monad-logger
|
||||||
, fast-logger >= 2.2 && < 2.5
|
, fast-logger
|
||||||
, wai-logger >= 2.2 && < 2.3
|
, wai-logger
|
||||||
, file-embed
|
, file-embed
|
||||||
, safe
|
, safe
|
||||||
, unordered-containers
|
, unordered-containers
|
||||||
|
13
stack.yaml
13
stack.yaml
@ -1,30 +1,27 @@
|
|||||||
# For more information, see: https://github.com/commercialhaskell/stack/blob/release/doc/yaml_configuration.md
|
# For more information, see: https://github.com/commercialhaskell/stack/blob/release/doc/yaml_configuration.md
|
||||||
|
|
||||||
# Specifies the GHC version and set of packages available (e.g., lts-3.5, nightly-2015-09-21, ghc-7.10.2)
|
# Specifies the GHC version and set of packages available (e.g., lts-3.5, nightly-2015-09-21, ghc-7.10.2)
|
||||||
resolver: lts-4.0
|
resolver: lts-9.14
|
||||||
|
|
||||||
# Local packages, usually specified by relative directory name
|
# Local packages, usually specified by relative directory name
|
||||||
packages:
|
packages:
|
||||||
- location: .
|
- location: .
|
||||||
- location:
|
|
||||||
git: https://github.com/Drezil/yesod-auth-oauth2.git
|
|
||||||
commit: 8412cb6c263b30f62c64a3be964448c09000f07c
|
|
||||||
- location:
|
- location:
|
||||||
git: https://github.com/Drezil/eve-api.git
|
git: https://github.com/Drezil/eve-api.git
|
||||||
commit: 5775b01785c684f27bb81a9d58cf2180205de3e5
|
commit: efeaf8e2cc19cd7528a17dc0aa40911bf19fa316
|
||||||
#- deps/yesod-auth-oauth2/
|
#- deps/yesod-auth-oauth2/
|
||||||
#- deps/eve-api/
|
#- deps/eve-api/
|
||||||
|
|
||||||
# Packages to be pulled from upstream that are not in the resolver (e.g., acme-missiles-0.3)
|
# Packages to be pulled from upstream that are not in the resolver (e.g., acme-missiles-0.3)
|
||||||
extra-deps: []
|
extra-deps:
|
||||||
|
- yesod-auth-oauth2-0.3.0
|
||||||
|
- load-env-0.1.1
|
||||||
|
|
||||||
# Override default flag values for local packages and extra-deps
|
# Override default flag values for local packages and extra-deps
|
||||||
flags:
|
flags:
|
||||||
neat:
|
neat:
|
||||||
library-only: false
|
library-only: false
|
||||||
dev: false
|
dev: false
|
||||||
yesod-auth-oauth2:
|
|
||||||
network-uri: true
|
|
||||||
|
|
||||||
# Extra package databases containing global packages
|
# Extra package databases containing global packages
|
||||||
extra-package-dbs: []
|
extra-package-dbs: []
|
||||||
|
Loading…
Reference in New Issue
Block a user