Prepare release 2.1.0.0 (#3748)

* Prepare release 2.1.0.0

* Update release ghc versions

* Fix release CI for unknown linux

* Generate ChangeLog from 2.0.0.0

* Update notable changes in ChangeLog

* Update index-state

* Add environment for vars context

* Free up disk space after running test

* Expand release notes

* Update supported ghc version page

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
This commit is contained in:
fendor 2023-08-12 12:40:41 +02:00 committed by GitHub
parent 099efbfb90
commit 9c56c3c0c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 272 additions and 365 deletions

View File

@ -39,6 +39,10 @@ test_all_hls() {
if ! [[ "${bin_noexe}" =~ "haskell-language-server-wrapper" ]] && ! [[ "${bin_noexe}" =~ "~" ]] ; then
if ghcup install ghc --set "${bin_noexe/haskell-language-server-/}" ; then
"${hls}" typecheck "${test_module}" || fail "failed to typecheck with HLS for GHC ${bin_noexe/haskell-language-server-/}"
# After running the test, free up disk space by deleting the unneeded GHC version.
# Helps us staying beneath the 14GB SSD disk limit.
ghcup rm ghc "${bin_noexe/haskell-language-server-/}"
else
fail "GHCup failed to install GHC ${bin_noexe/haskell-language-server-/}"
fi

View File

@ -1,163 +0,0 @@
name: Hackage
# See: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#concurrency.
concurrency:
group: ${{ github.head_ref }}-${{ github.workflow }}
cancel-in-progress: true
on:
workflow_dispatch:
inputs:
upload:
description: 'Whether packages should be uploaded'
required: true
default: 'false'
publish:
description: 'Wheter packages should be published as definitive'
required: true
default: 'false'
push:
branches:
- '*-hackage'
jobs:
check-and-upload-tarballs:
runs-on: ubuntu-latest
strategy:
fail-fast: ${{ github.event.inputs.upload != 'false' }}
matrix:
package: ["hie-compat", "hls-graph", "shake-bench",
"hls-plugin-api", "ghcide", "hls-test-utils",
"hls-cabal-plugin",
"hls-floskell-plugin", "hls-fourmolu-plugin",
"hls-ormolu-plugin", "hls-stylish-haskell-plugin",
"hls-class-plugin", "hls-eval-plugin", "hls-explicit-imports-plugin",
"hls-haddock-comments-plugin", "hls-hlint-plugin", "hls-stan-plugin",
"hls-module-name-plugin", "hls-pragmas-plugin",
"hls-rename-plugin", "hls-retrie-plugin",
"hls-splice-plugin", "hls-tactics-plugin",
"hls-call-hierarchy-plugin", "hls-alternate-number-format-plugin",
"hls-qualify-imported-names-plugin", "hls-code-range-plugin",
"hls-cabal-fmt-plugin",
"haskell-language-server"]
ghc: [ "9.0"
, "8.10"
]
exclude:
- ghc: "9.0"
package: "hls-stylish-haskell-plugin"
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup-build
with:
ghc: ${{ matrix.ghc }}
os: ${{ runner.os }}
shorten-hls: 'false'
- name: "Run cabal check"
run: |
if [[ ${{ matrix.package }} == *plugin ]]; then
cd plugins
fi
if [[ ${{ matrix.package }} != haskell-language-server ]]; then
cd ${{ matrix.package }}
fi
cabal check
- name: "Generate package dist tarball"
id: generate-dist-tarball
run: |
if [[ ${{ matrix.package }} == haskell-language-server ]]; then
cabal sdist --builddir=./
else
cabal sdist ${{ matrix.package }} --builddir=./
fi
echo ::set-output name=path::$(ls ./sdist/${{ matrix.package }}-*)
- name: "Unpack package source in an isolated location"
run: cabal unpack ${{ steps.generate-dist-tarball.outputs.path }} --destdir=./incoming
- name: "Try to get the current hackage version"
id: get-hackage-version
run: |
cd ./incoming
if cabal get $(ls -d ${{ matrix.package }}-*) --destdir=../current; then
echo ::set-output name=exists::true
else
echo ::set-output name=exists::false
fi
- name: "Compare the incoming and the current hackage version of the package"
id: compare-current-version
if: steps.get-hackage-version.outputs.exists == 'true'
run: |
# This will throw an error if there is any difference cause we have to bump up the package version
diff -r -x "*.md" -x "data" $(ls -d ./incoming/${{ matrix.package }}-*) $(ls -d ./current/${{ matrix.package }}-*)
- name: "Create appropiate cabal.project"
if: steps.get-hackage-version.outputs.exists != 'true'
run: |
cd $(ls -d ./incoming/${{ matrix.package }}-*)
echo "packages: . ../../* ../../plugins/*" > cabal.project
# These tweaks are already in cabal-901.project but we dont want to use the entire file,
# Only the tricks needed by the solver which we know will not make the hackage build fail.
# The solver takes in account all project packages, even if they are not gonna be effectively built
# (like stylish-haskell for ghc-9.0)
- name: "Add temporary needed allow-newer for ghc-9.0"
if: steps.get-hackage-version.outputs.exists != 'true' && matrix.ghc == '9.0'
run: |
cd $(ls -d ./incoming/${{ matrix.package }}-*)
# For stylish-haskell
echo " stylish-haskell:Cabal,stylish-haskell:ghc-lib-parser,stylish-haskell:aeson" >> cabal.project
- name: "Build main package components in isolation"
if: steps.get-hackage-version.outputs.exists != 'true'
run: |
cd $(ls -d ./incoming/${{ matrix.package }}-*)
cabal build
- name: "Build package tests and benchmarks in isolation"
if: steps.get-hackage-version.outputs.exists != 'true'
run: |
cd $(ls -d ./incoming/${{ matrix.package }}-*)
cabal build --enable-tests --enable-benchmarks
- name: "Generate haddock for hackage"
if: steps.get-hackage-version.outputs.exists != 'true'
run: |
cd $(ls -d ./incoming/${{ matrix.package }}-*)
cabal haddock --haddock-for-hackage
- name: "Upload package dist tarball"
if: steps.get-hackage-version.outputs.exists != 'true' && matrix.ghc == '8.10'
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.package }}
path: ${{ steps.generate-dist-tarball.outputs.path }}
upload-package:
# Runs triggered by *-hackage branches will upload packages
# cause inputs are blank when the workflow is not triggered manually
if: github.event.inputs.upload != 'false'
needs: check-and-upload-tarballs
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
with:
path: packages
- name: "Join all tarballs"
run: find ./packages -type f -name '*.tar.gz' -exec cp {} ./packages \;
- name: "Upload all tarballs to hackage"
uses: haskell-actions/hackage-publish@v1
with:
hackageToken: ${{ secrets.HACKAGE_AUTH_TOKEN }}
packagesPath: packages
# runs triggered by *-hackage branches will not publish packages definitely
publish: ${{ github.event.inputs.publish == 'true' }}

View File

@ -13,6 +13,11 @@ env:
jobs:
build-linux:
name: Build linux binaries
## We need the environment here, to have access to the `vars` context.
## Allows us to specify: `CABAL_CACHE_DISABLE=yes`.
## The environments can be seen in https://github.com/haskell/haskell-language-server/settings/environments
## assuming you have the proper permissions.
environment: CI
runs-on: ubuntu-latest
env:
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
@ -25,7 +30,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ghc: ["9.6.2", "9.4.5", "9.2.8", "9.2.7", "9.0.2", "8.10.7"]
ghc: ["9.6.2", "9.4.6", "9.4.5", "9.2.8", "9.0.2", "8.10.7"]
platform: [ { image: "debian:9"
, installCmd: "sed -i s/deb.debian.org/archive.debian.org/g /etc/apt/sources.list && sed -i 's|security.debian.org|archive.debian.org/|g' /etc/apt/sources.list && sed -i /-updates/d /etc/apt/sources.list && apt-get update && apt-get install -y"
, toolRequirements: "libnuma-dev zlib1g-dev libgmp-dev libgmp10 libssl-dev liblzma-dev libbz2-dev git wget lsb-release software-properties-common gnupg2 apt-transport-https gcc autoconf automake build-essential curl ghc gzip libffi-dev libncurses-dev libncurses5 libtinfo5 patchelf"
@ -105,20 +110,68 @@ jobs:
}
]
# TODO: rm
# we need a different image for 9.4.5, because GHC bindists are busted
# Instead of manually adding the Unknown Linux Bindist jobs here,
# it should be part of the matrix above.
# However, due to GHC 9.4 shenanigans, we need some special logic.
# https://gitlab.haskell.org/ghc/ghc/-/issues/22268
#
# Perhaps we can migrate *all* unknown linux builds to a uniform
# image.
include:
- ghc: 8.10.7
platform: { image: "rockylinux:8", installCmd: "yum -y install epel-release && yum install -y --allowerasing", toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf", DISTRO: "Unknown", ARTIFACT: "x86_64-linux-unknown", ADD_CABAL_ARGS: "--enable-split-sections" }
platform:
{ image: "rockylinux:8"
, installCmd: "yum -y install epel-release && yum install -y --allowerasing"
, toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf"
, DISTRO: "Unknown"
, ARTIFACT: "x86_64-linux-unknown"
, ADD_CABAL_ARGS: "--enable-split-sections"
}
- ghc: 9.0.2
platform: { image: "rockylinux:8", installCmd: "yum -y install epel-release && yum install -y --allowerasing", toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf", DISTRO: "Unknown", ARTIFACT: "x86_64-linux-unknown", ADD_CABAL_ARGS: "--enable-split-sections" }
- ghc: 9.2.7
platform: { image: "rockylinux:8", installCmd: "yum -y install epel-release && yum install -y --allowerasing", toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf", DISTRO: "Unknown", ARTIFACT: "x86_64-linux-unknown", ADD_CABAL_ARGS: "--enable-split-sections" }
platform:
{ image: "rockylinux:8"
, installCmd: "yum -y install epel-release && yum install -y --allowerasing"
, toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf"
, DISTRO: "Unknown"
, ARTIFACT: "x86_64-linux-unknown"
, ADD_CABAL_ARGS: "--enable-split-sections"
}
- ghc: 9.2.8
platform: { image: "rockylinux:8", installCmd: "yum -y install epel-release && yum install -y --allowerasing", toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf", DISTRO: "Unknown", ARTIFACT: "x86_64-linux-unknown", ADD_CABAL_ARGS: "--enable-split-sections" }
platform:
{ image: "rockylinux:8"
, installCmd: "yum -y install epel-release && yum install -y --allowerasing"
, toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf"
, DISTRO: "Unknown"
, ARTIFACT: "x86_64-linux-unknown"
, ADD_CABAL_ARGS: "--enable-split-sections"
}
- ghc: 9.4.5
platform: { image: "fedora:33", installCmd: "dnf install -y", toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf tree", DISTRO: "Unknown", ARTIFACT: "x86_64-linux-unknown", ADD_CABAL_ARGS: "--enable-split-sections" }
platform:
{ image: "fedora:27"
, installCmd: "dnf install -y"
, toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf"
, DISTRO: "Unknown"
, ARTIFACT: "x86_64-linux-unknown"
, ADD_CABAL_ARGS: "--enable-split-sections"
}
- ghc: 9.4.6
platform:
{ image: "fedora:27"
, installCmd: "dnf install -y"
, toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf"
, DISTRO: "Unknown"
, ARTIFACT: "x86_64-linux-unknown"
, ADD_CABAL_ARGS: "--enable-split-sections"
}
- ghc: 9.6.2
platform: { image: "rockylinux:8", installCmd: "yum -y install epel-release && yum install -y --allowerasing", toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf", DISTRO: "Unknown", ARTIFACT: "x86_64-linux-unknown", ADD_CABAL_ARGS: "--enable-split-sections" }
platform:
{ image: "rockylinux:8"
, installCmd: "yum -y install epel-release && yum install -y --allowerasing"
, toolRequirements: "autoconf automake binutils bzip2 coreutils curl elfutils-devel elfutils-libs findutils gcc gcc-c++ git gmp gmp-devel jq lbzip2 make ncurses ncurses-compat-libs ncurses-devel openssh-clients patch perl pxz python3 sqlite sudo wget which xz zlib-devel patchelf"
, DISTRO: "Unknown"
, ARTIFACT: "x86_64-linux-unknown"
, ADD_CABAL_ARGS: "--enable-split-sections"
}
container:
image: ${{ matrix.platform.image }}
steps:
@ -158,6 +211,11 @@ jobs:
build-arm:
name: Build ARM binary
## We need the environment here, to have access to the `vars` context.
## Allows us to specify: `CABAL_CACHE_DISABLE=yes`.
## The environments can be seen in https://github.com/haskell/haskell-language-server/settings/environments
## assuming you have the proper permissions.
environment: CI
runs-on: [self-hosted, Linux, ARM64]
env:
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
@ -173,7 +231,7 @@ jobs:
strategy:
fail-fast: true
matrix:
ghc: ["9.6.2", "9.4.5", "9.2.8", "9.2.7", "9.0.2", "8.10.7"]
ghc: ["9.6.2", "9.4.6", "9.4.5", "9.2.8", "9.0.2", "8.10.7"]
steps:
- uses: docker://arm64v8/ubuntu:focal
name: Cleanup (aarch64 linux)
@ -214,6 +272,11 @@ jobs:
build-mac-x86_64:
name: Build binary (Mac x86_64)
## We need the environment here, to have access to the `vars` context.
## Allows us to specify: `CABAL_CACHE_DISABLE=yes`.
## The environments can be seen in https://github.com/haskell/haskell-language-server/settings/environments
## assuming you have the proper permissions.
environment: CI
runs-on: macOS-11
env:
MACOSX_DEPLOYMENT_TARGET: 10.13
@ -228,7 +291,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ghc: ["9.6.2", "9.4.5", "9.2.8", "9.2.7", "9.0.2", "8.10.7"]
ghc: ["9.6.2", "9.4.6", "9.4.5", "9.2.8", "9.0.2", "8.10.7"]
steps:
- name: Checkout code
uses: actions/checkout@v3
@ -253,6 +316,11 @@ jobs:
build-mac-aarch64:
name: Build binary (Mac aarch64)
## We need the environment here, to have access to the `vars` context.
## Allows us to specify: `CABAL_CACHE_DISABLE=yes`.
## The environments can be seen in https://github.com/haskell/haskell-language-server/settings/environments
## assuming you have the proper permissions.
environment: CI
runs-on: [self-hosted, macOS, ARM64]
env:
MACOSX_DEPLOYMENT_TARGET: 10.13
@ -268,7 +336,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ghc: ["9.6.2", "9.4.5", "9.2.8", "9.2.7", "8.10.7"]
ghc: ["9.6.2", "9.4.6", "9.4.5", "9.2.8", "8.10.7"]
steps:
- name: Checkout code
uses: actions/checkout@v3
@ -304,6 +372,11 @@ jobs:
build-win:
name: Build binary (Win)
## We need the environment here, to have access to the `vars` context.
## Allows us to specify: `CABAL_CACHE_DISABLE=yes`.
## The environments can be seen in https://github.com/haskell/haskell-language-server/settings/environments
## assuming you have the proper permissions.
environment: CI
runs-on: windows-latest
env:
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
@ -317,7 +390,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ghc: ["9.6.2", "9.4.5", "9.2.8", "9.2.7", "9.0.2", "8.10.7"]
ghc: ["9.6.2", "9.4.6", "9.4.5", "9.2.8", "9.0.2", "8.10.7"]
steps:
- name: install windows deps
shell: pwsh

View File

@ -1,8 +1,149 @@
# Changelog for haskell-language-server
## 2.1.0.0
* Binaries for GHC 9.4.6
* Completions for .cabal files
* Performance improvements
* Show package name and its version while hovering on import statements
([#3691](https://github.com/haskell/haskell-language-server/pull/3691))
* Fix code edits in lsp spec compliant editors like helix.
([#3643](https://github.com/haskell/haskell-language-server/pull/3643))
### Pull requests merged
- Update to latest lsp packages
([#3747](https://github.com/haskell/haskell-language-server/pull/3747)) by @joyfulmantis
- Remove unnecessary allow-newer in stack.yaml
([#3746](https://github.com/haskell/haskell-language-server/pull/3746)) by @July541
- Log fourmolu and ormolu version that hls using
([#3744](https://github.com/haskell/haskell-language-server/pull/3744)) by @July541
- Various PluginError PR suggestions I missed earlier
([#3737](https://github.com/haskell/haskell-language-server/pull/3737)) by @joyfulmantis
- Add resolve support in refine imports by merging it with explicit imports
([#3729](https://github.com/haskell/haskell-language-server/pull/3729)) by @joyfulmantis
- Fix other file goto definition
([#3725](https://github.com/haskell/haskell-language-server/pull/3725)) by @nlander
- Fix Nix builds
([#3724](https://github.com/haskell/haskell-language-server/pull/3724)) by @cydparser
- Better plugin error infrastructure
([#3717](https://github.com/haskell/haskell-language-server/pull/3717)) by @joyfulmantis
- Move Recorder to hls-plugin-api
([#3714](https://github.com/haskell/haskell-language-server/pull/3714)) by @joyfulmantis
- Actually force usages
([#3713](https://github.com/haskell/haskell-language-server/pull/3713)) by @wz1000
- Best-effort support of Qualified Imports in GHC 9.4
([#3712](https://github.com/haskell/haskell-language-server/pull/3712)) by @konn
- Skip test if only CODEOWNERS changed
([#3707](https://github.com/haskell/haskell-language-server/pull/3707)) by @July541
- Update stack stuff
([#3706](https://github.com/haskell/haskell-language-server/pull/3706)) by @July541
- Mark hls-floskell-plugin as tier 3
([#3705](https://github.com/haskell/haskell-language-server/pull/3705)) by @July541
- Remove isovector as an owner
([#3700](https://github.com/haskell/haskell-language-server/pull/3700)) by @isovector
- Bump haskell/actions from 2.4.3 to 2.4.4 in /.github/actions/setup-build
([#3699](https://github.com/haskell/haskell-language-server/pull/3699)) by @dependabot[bot]
- Bump haskell/actions from 2.4.3 to 2.4.4
([#3698](https://github.com/haskell/haskell-language-server/pull/3698)) by @dependabot[bot]
- Catch exceptions in commands and use lsp null
([#3696](https://github.com/haskell/haskell-language-server/pull/3696)) by @joyfulmantis
- Show package name and its version while hovering on import statements
([#3691](https://github.com/haskell/haskell-language-server/pull/3691)) by @July541
- Resolve refactoring
([#3688](https://github.com/haskell/haskell-language-server/pull/3688)) by @joyfulmantis
- Prefer non-boot files when creating the FinderCache.
([#3687](https://github.com/haskell/haskell-language-server/pull/3687)) by @wz1000
- Some fixes for multi component stuff
([#3686](https://github.com/haskell/haskell-language-server/pull/3686)) by @wz1000
- Further hlint resolve changes.
([#3685](https://github.com/haskell/haskell-language-server/pull/3685)) by @joyfulmantis
- docs (plugin-support): fix plugin name typo
([#3683](https://github.com/haskell/haskell-language-server/pull/3683)) by @PiDelport
- Resolve for explicit-imports
([#3682](https://github.com/haskell/haskell-language-server/pull/3682)) by @joyfulmantis
- Hls 2.0.0.1 forward port
([#3680](https://github.com/haskell/haskell-language-server/pull/3680)) by @hasufell
- Resolve 2: Support for resolve in hls-hlint-plugin
([#3679](https://github.com/haskell/haskell-language-server/pull/3679)) by @joyfulmantis
- Resolve 0: Generic support for resolve in hls packages
([#3678](https://github.com/haskell/haskell-language-server/pull/3678)) by @joyfulmantis
- Ship hls-hlint-plugin for ghc-9.6
([#3677](https://github.com/haskell/haskell-language-server/pull/3677)) by @July541
- Remove extra call to newHscEnvEqWithImportPaths
([#3676](https://github.com/haskell/haskell-language-server/pull/3676)) by @nlander
- Fixes pragma plugin offering incorrect code actions #3673
([#3674](https://github.com/haskell/haskell-language-server/pull/3674)) by @joyfulmantis
- Restore short option for logfile
([#3672](https://github.com/haskell/haskell-language-server/pull/3672)) by @michaelpj
- Enable stylish-haskell for 9.6
([#3670](https://github.com/haskell/haskell-language-server/pull/3670)) by @michaelpj
- Bump supported ormolu, allow for 9.6
([#3668](https://github.com/haskell/haskell-language-server/pull/3668)) by @michaelpj
- Bump cachix/install-nix-action from 21 to 22
([#3666](https://github.com/haskell/haskell-language-server/pull/3666)) by @dependabot[bot]
- Add arguments to direct logs to various locations
([#3665](https://github.com/haskell/haskell-language-server/pull/3665)) by @michaelpj
- Support fourmolu 0.13
([#3662](https://github.com/haskell/haskell-language-server/pull/3662)) by @brandonchinn178
- Resolve 1: Support for resolve in overloaded-record-dot
([#3658](https://github.com/haskell/haskell-language-server/pull/3658)) by @joyfulmantis
- fix ISO8601 related deprecation in time
([#3654](https://github.com/haskell/haskell-language-server/pull/3654)) by @HugoPeters1024
- Add a log-level argument to set the log level
([#3651](https://github.com/haskell/haskell-language-server/pull/3651)) by @michaelpj
- Update Contributing.md
([#3650](https://github.com/haskell/haskell-language-server/pull/3650)) by @VeryMilkyJoe
- Commit to prettyprinter >= 1.7
([#3649](https://github.com/haskell/haskell-language-server/pull/3649)) by @michaelpj
- Add missing Monad constraint in the eval plugin
([#3648](https://github.com/haskell/haskell-language-server/pull/3648)) by @sandydoo
- hls-pragmas-plugin: Reduce noisy completions
([#3647](https://github.com/haskell/haskell-language-server/pull/3647)) by @akshaymankar
- Correctly pass VersionedTextDocumentIdentifier through hls
([#3643](https://github.com/haskell/haskell-language-server/pull/3643)) by @maralorn
- Add an assist for importing record fields when using OverloadedRecordDot
([#3642](https://github.com/haskell/haskell-language-server/pull/3642)) by @simmsb
- update flakes to compile with ghc928 and ghc962
([#3641](https://github.com/haskell/haskell-language-server/pull/3641)) by @smunix
- Split pragmas plugin by providers + decrease disable-warning priority
([#3640](https://github.com/haskell/haskell-language-server/pull/3640)) by @mrcjkb
- Reintroduce cabal-install in flake.nix
([#3637](https://github.com/haskell/haskell-language-server/pull/3637)) by @cgeorgii
- Delete dead cbits
([#3635](https://github.com/haskell/haskell-language-server/pull/3635)) by @michaelpj
- Simplify selection of GHCs to build on
([#3633](https://github.com/haskell/haskell-language-server/pull/3633)) by @michaelpj
- Support fourmolu 0.13.0.0
([#3631](https://github.com/haskell/haskell-language-server/pull/3631)) by @brandonchinn178
- Bump haskell/actions from 2.4.1 to 2.4.3 in /.github/actions/setup-build
([#3627](https://github.com/haskell/haskell-language-server/pull/3627)) by @dependabot[bot]
- Bump haskell/actions from 2.4.1 to 2.4.3
([#3626](https://github.com/haskell/haskell-language-server/pull/3626)) by @dependabot[bot]
- remove ghc minor versions in nix flake package builds
([#3625](https://github.com/haskell/haskell-language-server/pull/3625)) by @smunix
- HLS for the new generated LSP 2 release
([#3621](https://github.com/haskell/haskell-language-server/pull/3621)) by @joyfulmantis
- Keep plugin id of cabal-fmt in sync with default config id
([#3615](https://github.com/haskell/haskell-language-server/pull/3615)) by @VeryMilkyJoe
- Fix some grammar mistakes and typos
([#3614](https://github.com/haskell/haskell-language-server/pull/3614)) by @VeryMilkyJoe
- Bump cachix/install-nix-action from 20 to 21
([#3612](https://github.com/haskell/haskell-language-server/pull/3612)) by @dependabot[bot]
- fix: remove the `Indexing` progress message when exeption in withHieDb
([#3610](https://github.com/haskell/haskell-language-server/pull/3610)) by @guibou
- Bump haskell/actions from 2.4.0 to 2.4.1 in /.github/actions/setup-build
([#3604](https://github.com/haskell/haskell-language-server/pull/3604)) by @dependabot[bot]
- Bump haskell/actions from 2.4.0 to 2.4.1
([#3603](https://github.com/haskell/haskell-language-server/pull/3603)) by @dependabot[bot]
- Cabal file completions
([#3268](https://github.com/haskell/haskell-language-server/pull/3268)) by @VeryMilkyJoe
- Share ModuleGraphs for all files
([#3232](https://github.com/haskell/haskell-language-server/pull/3232)) by @wz1000
## 2.0.0.1
- Add overloaded record dot plugin intial version (closes #3350) (#3560)
- Add overloaded record dot plugin initial version (closes #3350) (#3560)
- Binaries for GHC 9.2.8 and GHC 9.6.2
## 2.0.0.0

View File

@ -18,18 +18,13 @@ import System.Environment
import System.Process
main = do
callCommand "git fetch --tags"
tags <- filter (isPrefixOf "1.") . lines <$>
readProcess "git" ["tag", "--list", "--sort=v:refname"] ""
lastDateStr <- last . lines <$> readProcess "git" ["show", "-s", "--format=%cI", "-1", last tags] ""
args <- getArgs
let (githubReq,tag) = case args of
token:tag:_ -> (github (OAuth $ BS.pack token), tag)
prs <- githubReq $ pullRequestsForR "haskell" "haskell-language-server" stateClosed FetchAll
lastDateStr <- last . lines <$> readProcess "git" ["show", "-s", "--format=%cI", "-1", tag] ""
lastDate <- zonedTimeToUTC <$> iso8601ParseM lastDateStr
args <- getArgs
let githubReq = case args of
[] -> github'
token:_ -> github (OAuth $ BS.pack token)
prs <- githubReq $ pullRequestsForR "haskell" "haskell-language-server" stateClosed FetchAll
let prsAfterLastTag = either (error . show)
(foldMap (\pr -> [pr | inRange pr]))
prs
@ -39,5 +34,5 @@ main = do
forM_ prsAfterLastTag $ \SimplePullRequest{..} ->
putStrLn $ T.unpack $ "- " <> simplePullRequestTitle <>
"\n([#" <> T.pack (show $ unIssueNumber simplePullRequestNumber) <> "](" <> getUrl simplePullRequestHtmlUrl <> "))" <>
"\n ([#" <> T.pack (show $ unIssueNumber simplePullRequestNumber) <> "](" <> getUrl simplePullRequestHtmlUrl <> "))" <>
" by @" <> untagName (simpleUserLogin simplePullRequestUser)

View File

@ -4,23 +4,53 @@
- [ ] check ghcup supports new GHC releases if any
- [ ] set the supported GHCs in workflow file `.github/workflows/release.yaml`
- There is currently a list of GHC versions for each major platform. Search for `ghc: [` to find all lists.
- Look for `TODO:` to find locations that require extra care for GHC versions.
- [ ] check all plugins still work if release includes code changes
- [ ] bump package versions in all `*.cabal` files (same version as hls)
- HLS uses a lockstep versioning. The core packages and all plugins use the same version number, and only support exactly the this version.
- Exceptions:
- `hie-compat` requires no automatic version bump.
- `shake-bench` is an internal testing tool, not exposed to the outside world. Thus, no version bump required for releases.
- For updating cabal files, the following script can be used:
- ```sh
# Update all `version:` fields
sed -ri "s/^version:( +)2.1.0.0/version:\12.2.0.0/" **/*.cabal
# Update all constraints expected to be in the form `== <version>`.
# We usually don't force an exact version, so this is relatively unambiguous.
# We could introduce some more ad-hoc parsing, if there is still ambiguity.
sed -ri "s/== 2.1.0.0/== 2.2.0.0/" **/*.cabal
```
- It still requires manual verification and review
- [ ] generate and update changelog
- Generate a ChangeLog via `./GenChangelogs.hs <api-key> <tag>`
- `<tag>` is the git tag you want to generate the ChangeLog from.
- `<api-key>` is a github access key: https://github.com/settings/tokens
- [ ] create release branch as `wip/<version>`
- `git switch -c wip/<version>`
- [ ] create release tag as `<version>`
- `git tag <version>`
- [ ] trigger release pipeline by pushing the tag
- this creates a draft release
- [ ] run `sh scripts/release/download-gh-artifacts <version> <your-gpg-email>`
- `git push <remote> <version>`
- [ ] run `sh scripts/release/download-gh-artifacts.sh <version> <your-gpg-email>`
- downloads artifacts to `gh-release-artifacts/<version>/`
- also downloads FreeBSD bindist from circle CI
- adds signatures
- [ ] upload artifacts to downloads.haskell.org manually from `gh-release-artifacts/<version>/`
- You require sftp access, contact wz1000, bgamari or chreekat
- For uploading, rename `gh-release-artifacts/<version>` to `gh-release-artifacts/haskell-language-server-<version>`
- `cd gh-release-artifacts/haskell-language-server-<version>`
- `SIGNING_KEY=... ../../release/upload.sh upload`
- Your SIGNING_KEY can be obtained with `gpg --list-secret-keys --keyid-format=long`
- Afterwards, the artifacts are available at: `https://downloads.haskell.org/~hls/haskell-language-server-<version>/`
- Run `SIGNING_KEY=... ../../release/upload.sh purge_all` to remove CDN caches
- [ ] create PR to [ghcup-metadata](https://github.com/haskell/ghcup-metadata)
- [ ] update `ghcup-0.0.7.yaml` and `ghcup-vanilla-0.0.7.yaml`
- can use `sh scripts/release/create-yaml-snippet.sh <version>` to generate a snippet that can be manually inserted into the yaml files
- [ ] update `hls-metadata-0.0.1.json`
- utilize `cabal run ghcup-gen -- generate-hls-ghcs -f ghcup-0.0.7.yaml --format json --stdout` in the root of ghcup-metadata repository
- Be sure to mark the correct latest version and add the 'recommended' tag to the latest release.
- [ ] get sign-off on release
- from wz1000, michealpj, maerwald and fendor
- [ ] publish release on github

View File

@ -55,7 +55,7 @@ package *
write-ghc-environment-files: never
index-state: 2023-08-06T10:37:15Z
index-state: 2023-08-09T10:37:15Z
constraints:
-- For GHC 9.4, older versions of entropy fail to build on Windows

View File

@ -1,174 +0,0 @@
# Releases and distributable binaries
Starting with 0.2.1.0 haskell-language-server provides pre-built binaries on
each [GitHub release](https://github.com/haskell/haskell-language-server/releases).
These binaries are used by the [vscode-haskell extension](https://github.com/haskell/vscode-haskell)
to provide automatic installation for users on VS Code, but they can also be installed manually
when added to the path.
Starting with 0.8.0.0 haskell-language-server and all its related packages
(core libraries like ghcide, plugins and hls itself) is being released on
[hackage](https://hackage.haskell.org/package/haskell-language-server) as well.
This allows cabal users to install it with `cabal install haskell-language-server`
and it is being used in nix environments.
Since 1.7.0.0, HLS binaries are no longer uploaded to GitHub but to [downloads.haskell.org](https://downloads.haskell.org/~hls/).
[GHCup](https://www.haskell.org/ghcup/) uses these binaries to enable automatic installation of HLS binaries in
various lsp-client plugins, such as [vscode-haskell](https://github.com/haskell/vscode-haskell).
## Minimal checklist
### prerelease sanity checks
- [ ] check that all plugins work according to their [support tiers](../support/plugin-support.md)
- [ ] set the supported GHC versions and their corresponding cabal project-files in `bindist/ghcs` according to the [GHC version deprecation policy](../support/ghc-version-support.md#ghc-version-deprecation-policy)
- [ ] [trigger manually](https://docs.github.com/es/actions/managing-workflow-runs/manually-running-a-workflow) the hackage workflow *without* uploading the packages
- [ ] trigger manually the build workflow
- [ ] create a prerelease tag `${version}-check-gitlab` and push it to the [project repo in gitlab](https://gitlab.haskell.org/haskell/haskell-language-server) to check the build is fine
### github release
- [ ] generate the list of pull requests finished since the last release using the [haskell script](https://github.com/haskell/haskell-language-server/blob/master/GenChangelogs.hs) in the project root.
Nix users should run command `gen-hls-changelogs` (a wrapper of the script) in nix-shell instead.
- [ ] add that list to the actual [Changelog](https://github.com/haskell/haskell-language-server/blob/master/ChangeLog.md) with a description of the release.
- [ ] bump up versions of changed packages. All are optional but [haskell-language-server itself](https://github.com/haskell/haskell-language-server/blob/master/haskell-language-server.cabal).
- [ ] create the tag and make an initial prerelease to trigger the ci workflow (see details below)
- [ ] contact ghcup team (#haskell-ghcup irc channel or via its [repo](https://github.com/haskell/ghcup-metadata)) to try to sync our release and its inclusion in ghcup
- [ ] in the github release edit page, check the attached binaries and the release description (usually the changelog entry) and uncheck the prerelease box
- [ ] make public the release in the usual social channels (not required but useful to spread the word :slightly_smiling_face:):
- [ ] irc
- [ ] matrix
- [ ] twitter
- [ ] discord
- [ ] discourse
- [ ] reddit
### hackage release
- [ ] bump up package versions following the [pvp specification](https://pvp.haskell.org/) if they are not already updated. You could use [policeman](https://github.com/kowainik/policeman) to help with this step.
- [ ] create ${version}-hackage branch to trigger the hackage github workflow which will upload all changed packages to hackage as candidates
- [ ] for new plugins or packages, update hackage uploaders to add the author of the plugin/package and some hls maintainer(s) other than the owner of the hackage api key used to upload them (it has to be done by the owner of the api key, actually @pepeiborra)
- [ ] check manually candidates in hackage
- [ ] publish them definitely triggering a manual run of the hackage workflow setting the upload and publish inputs to `true`
### ghcup release
- [ ] push the release tag to the [haskell-language-server gitlab repo](https://gitlab.haskell.org/haskell/haskell-language-server) to trigger the build of ghcup specific artifacts
- [ ] download specific artifacts [only available in the gitlab build](#haskell-gitlab-release-pipeline) and compute their sha256sum
- [ ] upload them to the github release and complete the SHA256SUMS file
- [ ] change ghcup metadata to include the new release in <https://github.com/haskell/ghcup-metadata>
- example pull request [here](https://github.com/haskell/ghcup-metadata/pull/11)
## Making a new release of haskell-language-server in github
Go to the [GitHub releases
page](https://github.com/haskell/haskell-language-server/releases) for
haskell-language-server and start to create a new release. Choose or create a
tag, fill out the release notes etc., but before you create it
**make sure to check the pre-release checkbox**. This will prevent VS Code
*extension
users from attempting to install this version before the binaries are
created.
Once the release is created the [GitHub Actions
workflow](https://github.com/haskell/haskell-language-server/actions) will be
kicked off and will start creating binaries. They will be gzipped and
uploaded to the release.
It creates a `haskell-language-server-${os}-${ghcVersion}` binary for each platform
(Linux, macOS, Windows) and each GHC version that we currently support, as well
as a `haskell-language-server-wrapper-${os}` binary for each platform. Note that
only one wrapper binary is created per platform, and it should be built with the
most recent GHC version.
### ghcup
It creates a `haskell-language-server-${os}-${hlsVersion}.tar.gz` tarball with
the binaries for *all* supported ghc versions and a custom source tarball to help
downstream publishers in the distribution of the release.
The most prominent publisher using them is `ghcup`.
### checksums
The sha256 checksum of all artifacts are listed in the `SHA256SUMS` release file.
## Distributable binaries
In order to compile a hls binary on one machine and have it run on another, you
need to make sure there are **no hardcoded paths or data-files**.
### ghc libdir
One noteable thing which cannot be hardcoded is the **GHC libdir** this is
a path to `/usr/local/lib/ghc` or something like that, which was previously
baked in at compile-time with ghc-paths. Note that with static binaries we
can no longer use this because the GHC libdir of the GitHub Actions machine
will most almost certainly not exist on the end user's machine.
Therefore, hie-bios provides `getGhcRuntimeLibDir` to obtain this path on the fly
by consulting the cradle.
### Static binaries
We use the word "distributable" here because technically only the Linux builds
are static. They are built by passing `--enable-executable-static` to cabal.
Static binaries don't really exist on macOS, and there are issues with
proprietary code being linked in on Windows. However, the `.dylib`s linked on
macOS are all already provided by the system:
```bash
$ objdump -macho --dylibs-used haskell-language-server
haskell-language-server:
/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
/usr/lib/libcharset.1.dylib (compatibility version 2.0.0, current version 2.0.0)
```
## The GitHub Actions workflow
It just kicks off a matrix of jobs varying across GHC versions and OSs, building
the binaries with Cabal and extracting them from the dist-newstyle directory.
The binaries are built with -O2.
### Failing workflow
If the workflow fail and some binaries has been already uploaded,
those artifacts must be removed and the build should be re-ran (the build tries to upload themm all and it fails if there is an existing artifact with the same name)
### Updating release artifacts
*IMPORTANT: release artifacts must not be modified, cause it would break
its secure distribution using their hashes. We should only add new ones.*
To manually upload a new binary we should:
- Add the new tar/zip following the name conventions of existing ones
- `haskell-language-server-${os}-${ghcVersion}.gz` for `Linux` and `macOS` and `haskell-language-server-Windows-${ghcVersion}.exe.zip` for `Windows`
- the binary inside the gz file is named `haskell-language-server-${ghcVersion}` (with the `.exe` extension for `Windows`). Note that the binary name does not contain the `${os}` part.
- Add the executable to the existing tar `haskell-language-server-${os}-${ghcVersion}.tar.gz` *locally* and upload it under a new name `haskell-language-server-${os}-${ghcVersion}-rev${n}.tar.gz` following the same schema for the binary as the previous one.
- `-rev${n}` is the next revision number of the tarball, starting at 1.
- we should contact users of the tarball (particularly ghcup) to notify the change
## Hackage release workflow
We aim to do hackage releases following the github ones described above.
To help in that job we have added a [github workflow](https://github.com/haskell/haskell-language-server/blob/master/.github/workflows/hackage.yml)
That script checks, generates the tar.gz files, unpacks and builds them in isolation
against hackage head if the package version in the branch is different from hackage.
If the package in the branch has the same version as the released one, it will check
the relevant files have not changed and will throw an error otherwise.
You can trigger the build manually.
The script will upload the tarballs as candidates, maintainers will have to check and publish them definitely.
## haskell gitlab release pipeline
The project is present in the haskell gitlab server: <https://gitlab.haskell.org/haskell/haskell-language-server>
The main motivation is to leverage the ci infrastructure which includes architectures not included in the github ci.
The specific architectures only available through gitlab are: `aarch64-darwin`, `aarch64-linux`, `armv7-linux`, `x86_64-freebsd12`, `x86_64-freebsd13`, `x86_64-linux-alpine`
The gitlab pipeline uses the configuration file [.gitlab-ci.yml](https://github.com/haskell/haskell-language-server/blob/master/.gitlab-ci.yml)
and the sh scripts in [.gitlab](https://github.com/haskell/haskell-language-server/tree/master/.gitlab)
It is triggered by pushing a tag to the gitlab repo.

View File

@ -19,12 +19,13 @@ Support status (see the support policy below for more details):
|--------------|--------------------------------------------------------------------------------------|-----------------------------------------------------------------------------|
| 9.6.2 | [latest](https://github.com/haskell/haskell-language-server/releases/latest) | basic support |
| 9.6.1 | [2.0.0.0](https://github.com/haskell/haskell-language-server/releases/tag/2.0.0.0) | basic support |
| 9.4.6 | [latest](https://github.com/haskell/haskell-language-server/releases/latest) | full support |
| 9.4.5 | [latest](https://github.com/haskell/haskell-language-server/releases/latest) | full support |
| 9.4.4 | [1.10.0.0](https://github.com/haskell/haskell-language-server/releases/tag/1.10.0.0) | deprecated |
| 9.4.3 | [1.9.1.0](https://github.com/haskell/haskell-language-server/releases/tag/1.9.1.0) | deprecated |
| 9.4.(1,2) | [1.8.0.0](https://github.com/haskell/haskell-language-server/releases/tag/1.8.0.0) | deprecated |
| 9.2.8 | [latest](https://github.com/haskell/haskell-language-server/releases/latest) | full support |
| 9.2.7 | [latest](https://github.com/haskell/haskell-language-server/releases/latest) | full support |
| 9.2.7 | [2.0.0.1](https://github.com/haskell/haskell-language-server/releases/tag/2.0.0.1) | full support |
| 9.2.(5,6) | [1.9.1.0](https://github.com/haskell/haskell-language-server/releases/tag/1.9.1.0) | deprecated |
| 9.2.(3,4) | [1.8.0.0](https://github.com/haskell/haskell-language-server/releases/tag/1.8.0.0) | deprecated |
| 9.2.(1,2) | [1.7.0.0](https://github.com/haskell/haskell-language-server/releases/tag/1.7.0.0) | deprecated |