From 75e94c46605e71f823ce6d9c33ffcf123289958b Mon Sep 17 00:00:00 2001 From: Alan Zimmerman Date: Tue, 18 Dec 2018 21:16:24 +0200 Subject: [PATCH] Bring in GHC 8.6.3 support As stackacke nightly from 2018-12-18 on supports it. --- .circleci/config.yml | 6 ++++++ Makefile | 4 ++-- README.md | 12 ++++++------ build-all.ps1 | 11 +++++++---- stack-8.6.3.yaml | 41 +++++++++++++++++++++++++++++++++++++++++ test/utils/TestUtils.hs | 4 +++- 6 files changed, 65 insertions(+), 13 deletions(-) create mode 100644 stack-8.6.3.yaml diff --git a/.circleci/config.yml b/.circleci/config.yml index 90996b47..b32e7f3b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -131,6 +131,11 @@ jobs: - STACK_FILE: "stack-8.6.2.yaml" <<: *defaults + ghc-8.6.3: + environment: + - STACK_FILE: "stack-8.6.3.yaml" + <<: *defaults + ghc-nightly: environment: - STACK_FILE: "stack.yaml" @@ -181,5 +186,6 @@ workflows: - ghc-8.4.4 - ghc-8.6.1 - ghc-8.6.2 + - ghc-8.6.3 - ghc-nightly - cabal diff --git a/Makefile b/Makefile index fd0aec61..7bfeea66 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,13 @@ BASEDIR=$(CURDIR) STACKLOCALBINDIR:=$(shell stack path --local-bin) -GHC_VERSIONS= 8.6.2 8.6.1 8.4.4 8.4.3 8.4.2 8.2.2 8.2.1 +GHC_VERSIONS= 8.6.3 8.6.2 8.6.1 8.4.4 8.4.3 8.4.2 8.2.2 8.2.1 all: help .PHONY: all -## Builds hie for all supported GHC versions (8.2.1, 8.2.2, 8.4.2, 8.4.3, 8.4.4, 8.6.1 and 8.6.2) +## Builds hie for all supported GHC versions (8.2.1, 8.2.2, 8.4.2, 8.4.3, 8.4.4, 8.6.1, 8.6.2 and 8.6.3) build: $(foreach version, $(GHC_VERSIONS), hie-$(version)) .PHONY: build diff --git a/README.md b/README.md index f0586195..f5f7b3dd 100644 --- a/README.md +++ b/README.md @@ -139,7 +139,7 @@ cabal update The GHC version you are going to install HIE for depends on which version of GHC you are using for your project. If you don't have a current project there are two potential options: -1. The Nightly GHC version ([currently](https://www.stackage.org/nightly) 8.6.2) +1. The Nightly GHC version ([currently](https://www.stackage.org/nightly) 8.6.3) 2. The LTS GHC version (which is [currently](https://www.stackage.org/lts) 8.4.4) By default in a stack project you will get the LTS version. @@ -152,15 +152,15 @@ stack ghc -- --version You can install an specific version or [all available GHC versions](#install-all-available-ghc-versions). -#### Install a specific GHC version 8.2.1 - 8.6.2 +#### Install a specific GHC version 8.2.1 - 8.6.3 We will use the `make` tools here to wrap `stack install`. The preferred installation mechanism is via `make`, as it makes sure the repo is synced, installs the required cabal libraries if missing, and makes copies of the executables with suffixes to be able to tell them apart. Install **Nightly** (and hoogle docs): ```bash -make hie-8.6.2 -make build-doc-8.6.2 +make hie-8.6.3 +make build-doc-8.6.3 ``` Install **LTS** (and hoogle docs): @@ -196,7 +196,7 @@ This is the simplest approach as it will install all GHC versions to match again This will: -* install all supported GHC versions (8.2.1 - 8.6.2) +* install all supported GHC versions (8.2.1 - 8.6.3) * name them as expected by the VS Code plugin * build local hoogle docs for each version @@ -240,7 +240,7 @@ cabal update This will: -* install all supported GHC versions (8.2.1 - 8.6.2) +* install all supported GHC versions (8.2.1 - 8.6.3) * name them as expected by the VS Code plugin * build local hoogle docs for each version diff --git a/build-all.ps1 b/build-all.ps1 index 20b10a76..8c5fa90f 100644 --- a/build-all.ps1 +++ b/build-all.ps1 @@ -5,18 +5,21 @@ $stackbindir = stack path --local-bin -$supported_versions = +$supported_versions = @{ "8.2.1" = "8.2" ; "8.2.2" = "8.2" ; "8.4.2" = "8.4" ; "8.4.3" = "8.4" ; "8.4.4" = "8.4" + ; "8.6.1" = "8.6" + ; "8.6.2" = "8.6" + ; "8.6.3" = "8.6" } function main($requested_versions) { $build_versions = $requested_versions | sort ` - | %{ + | %{ $major = $supported_versions[$_] if (-not $major) { bail_unsupported_version $_ } @{ version=$_; major=$major } @@ -45,5 +48,5 @@ function bail_unsupported_version($v) { exit } -if ($args) { main $args } -else { main $supported_versions.Keys } \ No newline at end of file +if ($args) { main $args } +else { main $supported_versions.Keys } diff --git a/stack-8.6.3.yaml b/stack-8.6.3.yaml new file mode 100644 index 00000000..175b6965 --- /dev/null +++ b/stack-8.6.3.yaml @@ -0,0 +1,41 @@ +resolver: nightly-2018-12-18 # GHC 8.6.3 +packages: +- . +- hie-plugin-api + +extra-deps: +- ./submodules/HaRe +- ./submodules/brittany +- ./submodules/cabal-helper +- ./submodules/ghc-mod +- ./submodules/ghc-mod/core + +- apply-refact-0.6.0.0 +- butcher-1.3.2.1 +- cabal-plan-0.4.0.0 +- constrained-dynamic-0.1.0.0 +- ekg-json-0.1.0.6 +- ekg-wai-0.1.0.3 +- haddock-api-2.21.0 +- hsimport-0.8.6 +# - lsp-test-0.5.0.2 +- monad-memo-0.4.1 +- multistate-0.8.0.1 +# - resolv-0.1.1.2 +- syz-0.2.0.0 +- temporary-1.2.1.1 +- yaml-0.8.32 + + + + +flags: + haskell-ide-engine: + pedantic: true + hie-plugin-api: + pedantic: true + +nix: + packages: [ icu libcxx zlib ] + +concurrent-tests: false diff --git a/test/utils/TestUtils.hs b/test/utils/TestUtils.hs index 7f767ad9..9d8d1c92 100644 --- a/test/utils/TestUtils.hs +++ b/test/utils/TestUtils.hs @@ -133,7 +133,9 @@ ghcVersion = GHCPre84 stackYaml :: FilePath stackYaml = -#if (defined(MIN_VERSION_GLASGOW_HASKELL) && (MIN_VERSION_GLASGOW_HASKELL(8,6,2,0))) +#if (defined(MIN_VERSION_GLASGOW_HASKELL) && (MIN_VERSION_GLASGOW_HASKELL(8,6,3,0))) + "stack-8.6.3.yaml" +#elif (defined(MIN_VERSION_GLASGOW_HASKELL) && (MIN_VERSION_GLASGOW_HASKELL(8,6,2,0))) "stack-8.6.2.yaml" #elif (defined(MIN_VERSION_GLASGOW_HASKELL) && (MIN_VERSION_GLASGOW_HASKELL(8,6,1,0))) "stack-8.6.1.yaml"