Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into kokobd/os-path
Browse files Browse the repository at this point in the history
  • Loading branch information
kokobd committed Sep 3, 2022
2 parents fc3d8f7 + 5b229b6 commit 3bb4355
Show file tree
Hide file tree
Showing 222 changed files with 6,247 additions and 4,127 deletions.
2 changes: 1 addition & 1 deletion .github/actions/setup-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ inputs:
cabal:
description: "Cabal version"
required: false
default: "3.6"
default: "3.8.1.0"
os:
description: "Operating system: Linux, Windows or macOS"
required: true
Expand Down
62 changes: 37 additions & 25 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ jobs:
strategy:
fail-fast: true
matrix:
ghc: [ "9.2.4"
ghc: [ "9.4.2"
, "9.4.1"
, "9.2.4"
, "9.2.3"
, "9.0.2"
, "8.10.7"
Expand All @@ -69,6 +71,9 @@ jobs:
]
include:
# only test supported ghc major versions
- os: ubuntu-latest
ghc: '9.4.2'
test: true
- os: ubuntu-latest
ghc: '9.2.4'
test: true
Expand All @@ -84,6 +89,9 @@ jobs:
- os: ubuntu-latest
ghc: '8.6.5'
test: true
- os: windows-latest
ghc: '9.4.2'
test: true
- os: windows-latest
ghc: '9.2.4'
test: true
Expand Down Expand Up @@ -156,99 +164,103 @@ jobs:
HLS_WRAPPER_TEST_EXE: hls-wrapper
run: cabal test wrapper-test --test-options="$TEST_OPTS --rerun-log-file .tasty-rerun-log-wrapper" || cabal test wrapper-test --test-options="$TEST_OPTS --rerun-log-file .tasty-rerun-log-wrapper" || cabal test wrapper-test --test-options="$TEST_OPTS --rerun-log-file .tasty-rerun-log-wrapper"

- if: matrix.test && matrix.ghc != '9.2.4'
- if: matrix.test && matrix.ghc != '9.2.4' && matrix.ghc != '9.4.2'
name: Test hls-brittany-plugin
run: cabal test hls-brittany-plugin --test-options="$TEST_OPTS" || cabal test hls-brittany-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-brittany-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-refactor-plugin
run: cabal test hls-refactor-plugin --test-options="$TEST_OPTS" || cabal test hls-refactor-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-refactor-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-floskell-plugin
run: cabal test hls-floskell-plugin --test-options="$TEST_OPTS" || cabal test hls-floskell-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-floskell-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-class-plugin
run: cabal test hls-class-plugin --test-options="$TEST_OPTS" || cabal test hls-class-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-class-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-pragmas-plugin
run: cabal test hls-pragmas-plugin --test-options="$TEST_OPTS" || cabal test hls-pragmas-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-pragmas-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-eval-plugin
run: cabal test hls-eval-plugin --test-options="$TEST_OPTS" || cabal test hls-eval-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-eval-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.ghc != '9.2.4'
- if: matrix.test && matrix.ghc != '9.2.4' && matrix.ghc != '9.4.2'
name: Test hls-haddock-comments-plugin
run: cabal test hls-haddock-comments-plugin --test-options="$TEST_OPTS" || cabal test hls-haddock-comments-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-haddock-comments-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.ghc != '9.2.4'
- if: matrix.test && matrix.ghc != '9.2.4' && matrix.ghc != '9.4.2'
name: Test hls-splice-plugin
run: cabal test hls-splice-plugin --test-options="$TEST_OPTS" || cabal test hls-splice-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-splice-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-stylish-haskell-plugin
run: cabal test hls-stylish-haskell-plugin --test-options="$TEST_OPTS" || cabal test hls-stylish-haskell-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-stylish-haskell-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-ormolu-plugin
run: cabal test hls-ormolu-plugin --test-options="$TEST_OPTS" || cabal test hls-ormolu-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-ormolu-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-fourmolu-plugin
run: cabal test hls-fourmolu-plugin --test-options="$TEST_OPTS" || cabal test hls-fourmolu-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-fourmolu-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.ghc != '9.2.4'
- if: matrix.test && matrix.ghc != '9.2.4' && matrix.ghc != '9.4.2'
name: Test hls-tactics-plugin test suite
run: cabal test hls-tactics-plugin --test-options="$TEST_OPTS" || cabal test hls-tactics-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-tactics-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-refine-imports-plugin test suite
run: cabal test hls-refine-imports-plugin --test-options="$TEST_OPTS" || cabal test hls-refine-imports-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-refine-imports-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-explicit-imports-plugin test suite
run: cabal test hls-explicit-imports-plugin --test-options="$TEST_OPTS" || cabal test hls-explicit-imports-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-explicit-imports-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-call-hierarchy-plugin test suite
run: cabal test hls-call-hierarchy-plugin --test-options="$TEST_OPTS" || cabal test hls-call-hierarchy-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-call-hierarchy-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.os != 'windows-latest'
- if: matrix.test && matrix.os != 'windows-latest' && matrix.ghc != '9.4.2'
name: Test hls-rename-plugin test suite
run: cabal test hls-rename-plugin --test-options="$TEST_OPTS" || cabal test hls-rename-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-rename-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-hlint-plugin test suite
run: cabal test hls-hlint-plugin --test-options="$TEST_OPTS" || cabal test hls-hlint-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-hlint-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.ghc != '9.0.1' && matrix.ghc != '9.0.2' && matrix.ghc != '9.2.4'
- if: matrix.test && matrix.ghc != '9.0.1' && matrix.ghc != '9.0.2' && matrix.ghc != '9.2.4' && matrix.ghc != '9.4.2'
name: Test hls-stan-plugin test suite
run: cabal test hls-stan-plugin --test-options="$TEST_OPTS" || cabal test hls-hlint-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-stan-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-module-name-plugin test suite
run: cabal test hls-module-name-plugin --test-options="$TEST_OPTS" || cabal test hls-module-name-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-module-name-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-alternate-number-format-plugin test suite
run: cabal test hls-alternate-number-format-plugin --test-options="$TEST_OPTS" || cabal test hls-alternate-number-format-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-alternate-number-format-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-qualify-imported-names-plugin test suite
run: cabal test hls-qualify-imported-names-plugin --test-options="$TEST_OPTS" || cabal test hls-qualify-imported-names-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-qualify-imported-names-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-code-range-plugin test suite
run: cabal test hls-code-range-plugin --test-options="$TEST_OPTS" || cabal test hls-code-range-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-code-range-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-change-type-signature test suite
run: cabal test hls-change-type-signature-plugin --test-options="$TEST_OPTS" || cabal test hls-change-type-signature-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-change-type-signature-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-gadt-plugin test suit
run: cabal test hls-gadt-plugin --test-options="$TEST_OPTS" || cabal test hls-gadt-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-gadt-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test && matrix.ghc != '9.4.2'
name: Test hls-explicit-fixity-plugin test suite
run: cabal test hls-explicit-fixity-plugin --test-options="$TEST_OPTS" || cabal test hls-explicit-fixity-plugin --test-options="$TEST_OPTS" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-explicit-fixity-plugin --test-options="$TEST_OPTS"

Expand Down
6 changes: 5 additions & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ variables:
# Commit of ghc/ci-images repository from which to pull Docker images
DOCKER_REV: "4ed1a4f27828ba96a34662dc954335e29b470cd2"

CABAL_INSTALL_VERSION: 3.6.2.0
CABAL_INSTALL_VERSION: 3.8.1.0

.windows_matrix: &windows_matrix
matrix:
Expand All @@ -21,6 +21,10 @@ variables:
CABAL_PROJECT: cabal.project
- GHC_VERSION: 9.2.4
CABAL_PROJECT: cabal.project
- GHC_VERSION: 9.4.1
CABAL_PROJECT: cabal.project
- GHC_VERSION: 9.4.2
CABAL_PROJECT: cabal.project

workflow:
rules:
Expand Down
3 changes: 3 additions & 0 deletions .hlint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
within:
- Development.IDE.Core.Shake
- Development.IDE.GHC.Util
- Development.IDE.Plugin.CodeAction.Util
- Development.IDE.Graph.Internal.Database
- Development.IDE.Graph.Internal.Paths
- Development.IDE.Graph.Internal.Profile
Expand Down Expand Up @@ -184,6 +185,7 @@
- Development.IDE.Core.Shake
- Development.IDE.Plugin.Completions
- Development.IDE.Plugin.CodeAction.ExactPrint
- Development.IDE.Plugin.CodeAction
- Development.IDE.Test
- Development.IDE.Graph.Internal.Profile
- Development.IDE.Graph.Internal.Rules
Expand Down Expand Up @@ -221,6 +223,7 @@
- Development.IDE.Core.Compile
- Development.IDE.Graph.Internal.Database
- Development.IDE.GHC.Util
- Development.IDE.Plugin.CodeAction.Util
- Wingman.Debug

# We really do not want novel usages of restricted functions, and mere
Expand Down
6 changes: 4 additions & 2 deletions bench/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ configurations:
# The implicitly included plugins are:
# - ghcide-core
# - ghcide-hover-and-symbols
<<<<<<< HEAD

# Uncomment below sections if needed
# - None: []
Expand All @@ -111,12 +112,13 @@ configurations:
# - ghcide-type-lenses
# - pragmas
# - Ghcide:
# - ghcide-completions
# - ghcide-type-lenses
# - Refactor:
# - ghcide-code-actions-bindings
# - ghcide-code-actions-fill-holes
# - ghcide-code-actions-imports-exports
# - ghcide-code-actions-type-signatures
# - ghcide-completions
# - ghcide-type-lenses
- All:
- alternateNumberFormat
- callHierarchy
Expand Down
2 changes: 2 additions & 0 deletions bindist/ghcs
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@
9.0.2,cabal.project
9.2.3,cabal.project
9.2.4,cabal.project
9.4.1,cabal.project
9.4.2,cabal.project
2 changes: 2 additions & 0 deletions bindist/ghcs-Msys
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@
9.0.2,cabal.project
9.2.3,cabal.project
9.2.4,cabal.project
9.4.1,cabal.project
9.4.2,cabal.project
42 changes: 41 additions & 1 deletion cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ packages:
./hls-graph
./ghcide
./ghcide-bench
./ghcide/test
./hls-plugin-api
./hls-test-utils
./plugins/hls-tactics-plugin
Expand Down Expand Up @@ -32,6 +33,7 @@ packages:
./plugins/hls-stan-plugin
./plugins/hls-gadt-plugin
./plugins/hls-explicit-fixity-plugin
./plugins/hls-refactor-plugin

-- Standard location for temporary packages needed for particular environments
-- For example it is used in the project gitlab mirror to help in the MAcOS M1 build script
Expand All @@ -46,9 +48,13 @@ package *

write-ghc-environment-files: never

index-state: 2022-08-15T06:53:13Z
index-state: 2022-08-29T06:53:13Z

constraints:
-- For GHC 9.4, older versions of entropy fail to build on Windows
entropy >= 0.4.1.10,
-- For GHC 9.4
basement >= 0.0.15,
hyphenation +embed,
-- remove this when hlint sets ghc-lib to true by default
-- https://github.com/ndmitchell/hlint/issues/1376
Expand All @@ -65,6 +71,16 @@ source-repository-package
tag: 7a0af7a8fd38045fd15fb13445bdcc7085325460
-- https://github.com/tibbe/ekg-json/pull/12

source-repository-package
type:git
location: https://github.com/wz1000/hiedb
tag: 67b92df2359558091df9102db5b701327308b930

source-repository-package
type:git
location: https://github.com/wz1000/hie-bios
tag: aa73d3d2eb89df0003d2468a105e326d71b62cc7

-- Remove me when a new version of lsp is released
source-repository-package
type:git
Expand All @@ -85,6 +101,30 @@ source-repository-package
tag: 77a434087b1f39ae6fd4bc6d88fddbcd1d23e185

allow-newer:
-- ghc-9.4
Chart-diagrams:lens,
Chart:lens,
co-log-core:base,
constraints-extras:base,
constraints-extras:template-haskell,
dependent-sum:some,
diagrams-contrib:base,
diagrams-contrib:lens,
diagrams-postscript:base,
diagrams-postscript:lens,
diagrams-svg:base,
diagrams-svg:lens,
ekg-json:base,
ghc-paths:Cabal,
haddock-library:base,
hie-bios:aeson,
hie-bios:ghc,
monoid-extras:base,
monoid-subclasses:vector,
svg-builder:base,
uuid:time,
vector-space:base,

-- ghc-9.2
----------
hiedb:base,
Expand Down
42 changes: 42 additions & 0 deletions configuration-ghc-94.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{ pkgs, inputs }:

let
disabledPlugins = [
"hls-hlint-plugin"
# That one is not technically a plugin, but by putting it in this list, we
# get it removed from the top level list of requirement and it is not pull
# in the nix shell.
"shake-bench"
];

hpkgsOverride = hself: hsuper:
with pkgs.haskell.lib;
{
hlsDisabledPlugins = disabledPlugins;
# YOLO
mkDerivation = args:
hsuper.mkDerivation (args // {
jailbreak = true;
doCheck = false;
});
} // (builtins.mapAttrs (_: drv: disableLibraryProfiling drv) {
# ptr-poker breaks on MacOS without SSE2 optimizations
# https://github.com/nikita-volkov/ptr-poker/issues/11
ptr-poker = hself.callCabal2nix "ptr-poker" inputs.ptr-poker { };

ghc-exactprint =
hself.callCabal2nix "ghc-exactprint" inputs.ghc-exactprint-150 { };
# Hlint is still broken
hlint = doJailbreak (hself.callCabal2nix "hlint" inputs.hlint { });

stylish-haskell = appendConfigureFlag hsuper.stylish-haskell "-fghc-lib";

# Re-generate HLS drv excluding some plugins
haskell-language-server =
hself.callCabal2nixWithOptions "haskell-language-server" ./.
(pkgs.lib.concatStringsSep " " [ "-fpedantic" "-f-hlint" ]) { };
});
in {
inherit disabledPlugins;
tweakHpkgs = hpkgs: hpkgs.extend hpkgsOverride;
}
Loading

0 comments on commit 3bb4355

Please sign in to comment.