From de75eb254b43a6cd38b94e7916781f796891cc1e Mon Sep 17 00:00:00 2001 From: Dmitrii Kovanikov Date: Tue, 9 Apr 2019 17:02:54 +0800 Subject: [PATCH] [#304] Bump up to relude-0.5.0 and brick-0.47 (#307) * [#304] Bump up to relude-0.5.0 and brick-0.47 Resolves #304 * Fix tests --- .travis.yml | 2 +- appveyor.yml | 3 --- stack-8.2.2.yaml | 12 ++++++++---- stack-8.4.4.yaml | 16 ++++++++++------ stack.yaml | 8 +------- summoner-cli/CHANGELOG.md | 13 +++++++------ summoner-cli/src/Summoner/Template/GitHub.hs | 3 --- summoner-cli/summoner.cabal | 2 +- .../test/golden/fullProject/appveyor.yml | 3 --- summoner-tui/src/Summoner/Tui.hs | 4 +++- summoner-tui/summoner-tui.cabal | 6 +++--- 11 files changed, 34 insertions(+), 38 deletions(-) diff --git a/.travis.yml b/.travis.yml index e728a214..d9dff154 100644 --- a/.travis.yml +++ b/.travis.yml @@ -55,7 +55,7 @@ script: else stack test --system-ghc --no-terminal fi - - curl https://raw.githubusercontent.com/kowainik/relude/988bbdd3a09df1159917012933780523644880e5/.hlint.yaml -o .hlint-relude.yaml + - curl https://raw.githubusercontent.com/kowainik/relude/55968311244690f5cc8b4484a37a63d988ea2ec4/.hlint.yaml -o .hlint-relude.yaml - curl -sSL https://raw.github.com/ndmitchell/neil/master/misc/travis.sh | sh -s -- hlint -h .hlint-relude.yaml summoner-cli/src/ summoner-cli/test/ summoner-tui/src/ after_success: diff --git a/appveyor.yml b/appveyor.yml index df2ac526..2e4fbe3f 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -14,9 +14,6 @@ install: environment: global: CABOPTS: "--store-dir=C:\\SR" - # Remove cache, there is no button on the web - # https://www.appveyor.com/docs/build-cache/#skipping-cache-operations-for-specific-build - APPVEYOR_CACHE_SKIP_RESTORE: true cache: - dist-newstyle diff --git a/stack-8.2.2.yaml b/stack-8.2.2.yaml index 4bf82aea..da1402e7 100644 --- a/stack-8.2.2.yaml +++ b/stack-8.2.2.yaml @@ -6,15 +6,19 @@ packages: extra-deps: - base-noprelude-4.10.1.0 - - brick-0.41.4 - - config-ini-0.2.4.0 - - relude-0.4.0 + - relude-0.5.0 - shellmet-0.0.1 - - tomland-1.0.0 - tree-diff-0.0.2 + + # tomland + - tomland-1.0.0 - megaparsec-7.0.4 # needed for tomland-0.5.0 - parser-combinators-1.0.0 # needed for megaparsec >= 7 - neat-interpolation-0.3.2.4 # needed because of megaparsec >= 7 + + # brick + - brick-0.47 + - config-ini-0.2.4.0 - vty-5.25.1 allow-newer: true diff --git a/stack-8.4.4.yaml b/stack-8.4.4.yaml index f10015bc..11a56d86 100644 --- a/stack-8.4.4.yaml +++ b/stack-8.4.4.yaml @@ -1,4 +1,4 @@ -resolver: lts-12.25 +resolver: lts-12.26 packages: - summoner-cli/ @@ -6,11 +6,15 @@ packages: extra-deps: - base-noprelude-4.11.1.0 - - brick-0.41.4 - - config-ini-0.2.4.0 - - relude-0.4.0 + - relude-0.5.0 - shellmet-0.0.1 + + # tomland - tomland-1.0.0 - - megaparsec-7.0.4 # needed for tomland-0.5.0 + - megaparsec-7.0.4 # needed for tomland - neat-interpolation-0.3.2.4 # needed because of megaparsec >= 7 - - vty-5.25.1 + + # brick + - brick-0.47 + - vty-5.25.1 # needed for brick + - config-ini-0.2.4.0 # needed for brick diff --git a/stack.yaml b/stack.yaml index 82d83d8a..ba140a76 100644 --- a/stack.yaml +++ b/stack.yaml @@ -1,14 +1,8 @@ -resolver: lts-13.15 +resolver: nightly-2019-04-09 packages: - summoner-cli/ - summoner-tui/ extra-deps: - - brick-0.41.5 - shellmet-0.0.1 - - tomland-1.0.0 - - config-ini-0.2.4.0 # needed for brick - - data-clist-0.1.2.2 # needed for brick - - text-zipper-0.10.1 # needed for brick - - word-wrap-0.4.1 # needed for brick diff --git a/summoner-cli/CHANGELOG.md b/summoner-cli/CHANGELOG.md index 45e98a0b..f41902b8 100644 --- a/summoner-cli/CHANGELOG.md +++ b/summoner-cli/CHANGELOG.md @@ -5,8 +5,9 @@ The changelog is available [on GitHub][2]. ## Unreleased: 1.3.0 -* [#151](https://github.com/kowainik/summoner/issues/151): - Make GHC-8.6.3 default. +* [#151](https://github.com/kowainik/summoner/issues/151), + [#295](https://github.com/kowainik/summoner/issues/295): + Add support for GHC-8.6. Make GHC-8.6.4 default. * [#268](https://github.com/kowainik/summoner/issues/268): Simplify process of adding custom prelude in the interactive mode. * [#272](https://github.com/kowainik/summoner/issues/272): @@ -16,8 +17,10 @@ The changelog is available [on GitHub][2]. * __Important:__ Summoner doesn't add old GHC versions into Travis matrix for Stack. See this Stack issue for reasoning: https://github.com/commercialhaskell/stack/issues/4488 -* [#286](https://github.com/kowainik/summoner/issues/286): - Bump up to `tomland-1.0.0` +* [#286](https://github.com/kowainik/summoner/issues/286), + [#288](https://github.com/kowainik/summoner/issues/304), + [#304](https://github.com/kowainik/summoner/issues/304): + Bump up to `tomland-1.0.0`, `relude-0.5.0`, `shellmet-0.0.1`, `brick-0.47`. * [#282](https://github.com/kowainik/summoner/issues/282): Allow users to extend the .gitignore file. * [#285](https://github.com/kowainik/summoner/issues/285): @@ -27,8 +30,6 @@ The changelog is available [on GitHub][2]. _Migration guide:_ Please, rename `warnings` field if you use one, it will be removed in the very next release. Use `ghc-options` instead. -* [#295](https://github.com/kowainik/summoner/issues/295): - Add support for ghc-8.6.4. * Drop support for GHC-8.6.3 on CI. Support GHC-8.6.4 on CI. * [#280](https://github.com/kowainik/summoner/issues/280): Support build with `cabal-install` on the AppVeyor CI. diff --git a/summoner-cli/src/Summoner/Template/GitHub.hs b/summoner-cli/src/Summoner/Template/GitHub.hs index c2937aad..281e55fc 100644 --- a/summoner-cli/src/Summoner/Template/GitHub.hs +++ b/summoner-cli/src/Summoner/Template/GitHub.hs @@ -255,9 +255,6 @@ gitHubFiles Settings{..} = environment: global: CABOPTS: "--store-dir=C:\\SR" - # Remove cache, there is no button on the web - # https://www.appveyor.com/docs/build-cache/#skipping-cache-operations-for-specific-build - APPVEYOR_CACHE_SKIP_RESTORE: true cache: - dist-newstyle diff --git a/summoner-cli/summoner.cabal b/summoner-cli/summoner.cabal index 20410a66..4a6a80b2 100644 --- a/summoner-cli/summoner.cabal +++ b/summoner-cli/summoner.cabal @@ -64,7 +64,7 @@ library , neat-interpolation ^>= 0.3.2.2 , optparse-applicative ^>= 0.14.2.0 , process ^>= 1.6.1.0 - , relude ^>= 0.4.0 + , relude ^>= 0.5.0 , shellmet ^>= 0.0.1 , text ^>= 1.2.3.0 , time ^>= 1.8 diff --git a/summoner-cli/test/golden/fullProject/appveyor.yml b/summoner-cli/test/golden/fullProject/appveyor.yml index 9875ec9a..57bfd1fe 100644 --- a/summoner-cli/test/golden/fullProject/appveyor.yml +++ b/summoner-cli/test/golden/fullProject/appveyor.yml @@ -14,9 +14,6 @@ install: environment: global: CABOPTS: "--store-dir=C:\\SR" - # Remove cache, there is no button on the web - # https://www.appveyor.com/docs/build-cache/#skipping-cache-operations-for-specific-build - APPVEYOR_CACHE_SKIP_RESTORE: true cache: - dist-newstyle diff --git a/summoner-tui/src/Summoner/Tui.hs b/summoner-tui/src/Summoner/Tui.hs index a0096886..5cfc2d52 100644 --- a/summoner-tui/src/Summoner/Tui.hs +++ b/summoner-tui/src/Summoner/Tui.hs @@ -310,7 +310,9 @@ runTuiShowLicense (toText -> name) = case parseLicenseName name of -- | Runs brick application with given start state. runApp :: Ord n => App s e n -> s -> IO s -runApp = customMain buildVty Nothing +runApp app s = do + initialVty <- buildVty + customMain initialVty buildVty Nothing app s where buildVty :: IO V.Vty buildVty = do diff --git a/summoner-tui/summoner-tui.cabal b/summoner-tui/summoner-tui.cabal index 112ef947..15287a6f 100644 --- a/summoner-tui/summoner-tui.cabal +++ b/summoner-tui/summoner-tui.cabal @@ -18,7 +18,7 @@ extra-doc-files: README.md , CHANGELOG.md tested-with: GHC == 8.2.2 , GHC == 8.4.4 - , GHC == 8.6.3 + , GHC == 8.6.4 source-repository head type: git @@ -41,12 +41,12 @@ library Prelude build-depends: base-noprelude >= 4.10 && < 4.13 - , brick ^>= 0.41.4 + , brick ^>= 0.47 , directory ^>= 1.3.0.2 , filepath ^>= 1.4.1.2 , microlens ^>= 0.4 , microlens-th ^>= 0.4 - , relude ^>= 0.4.0 + , relude ^>= 0.5.0 , summoner ^>= 1.3.0 , text ^>= 1.2.3.0 , vty ^>= 5.25