diff --git a/.circleci/config.yml b/.circleci/config.yml index 0ce6ca2740..ed50e17679 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -16,7 +16,7 @@ defaults: &defaults keys: - v4-stack-cache-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "resolver.txt" }} - # Looking for the string [skip ci] in all the json returned by https://docs.github.com/en/rest/reference/pulls#get-a-pull-request + # Looking for the string [skip circleci] in all the json returned by https://docs.github.com/en/rest/reference/pulls#get-a-pull-request - run: name: Skip ci setup command: | @@ -26,7 +26,12 @@ defaults: &defaults PULL_REQUEST_URL=${CIRCLE_PULL_REQUEST/github.com/api.github.com/repos} PULL_REQUEST_URL=${PULL_REQUEST_URL/pull/pulls} echo "PULL_REQUEST_URL: $PULL_REQUEST_URL" - SKIP_CI=$(curl $PULL_REQUEST_URL | grep -o "\\[skip ci\\]") + SKIP_CI=$(curl $PULL_REQUEST_URL | grep -o "\\[skip circleci\\]") + if [[ -z "$SKIP_CI" ]]; then + PULL_REQUEST_COMMENTS_URL=${PULL_REQUEST_URL/pulls/issues}/comments + echo "PULL_REQUEST_COMMENTS_URL: $PULL_REQUEST_COMMENTS_URL" + SKIP_CI=$(curl $PULL_REQUEST_COMMENTS_URL | grep -o "\\[skip circleci\\]") + fi echo "SKIP_CI: $SKIP_CI" fi echo "export SKIP_CI=$SKIP_CI" >> $BASH_ENV diff --git a/.github/workflows/bench.yml b/.github/workflows/bench.yml index 52be788dc8..48930e1eb1 100644 --- a/.github/workflows/bench.yml +++ b/.github/workflows/bench.yml @@ -17,7 +17,8 @@ jobs: cancel_others: true paths_ignore: '["**/docs/**", "**.md", "**/LICENSE", ".circleci/**", "install/**", "**.nix", "**/test/**", "flake.lock", "**/README.md", "FUNDING.yml"]' - bench-init: + bench_init: + if: needs.pre_job.outputs.should_skip != 'true' needs: pre_job runs-on: ${{ matrix.os }} @@ -28,19 +29,17 @@ jobs: os: [ubuntu-latest] steps: - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - uses: actions/checkout@v2 - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - run: git fetch origin master # check the master branch for benchmarking - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - uses: haskell/actions/setup@v1 + - uses: actions/checkout@v2 + + - run: git fetch origin master # check the master branch for benchmarking + + - uses: haskell/actions/setup@v1 with: ghc-version: ${{ matrix.ghc }} cabal-version: '3.2' enable-stack: false - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Cache Cabal + - name: Cache Cabal uses: actions/cache@v2 with: path: | @@ -52,55 +51,47 @@ jobs: v2-${{ runner.os }}-${{ matrix.ghc }}-bench- v2-${{ runner.os }}-${{ matrix.ghc }} - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - run: cabal update + - run: cabal update # max-backjumps is increased as a temporary solution # for dependency resolution failure - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - run: cabal configure --enable-benchmarks --max-backjumps 12000 + - run: cabal configure --enable-benchmarks --max-backjumps 12000 - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Build + - name: Build shell: bash run: cabal build ghcide:benchHist - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Bench init + - name: Bench init shell: bash run: cabal bench ghcide:benchHist -j --benchmark-options="all-binaries" # tar is required to preserve file permissions # compression speeds up upload/download nicely - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: tar workspace + - name: tar workspace shell: bash run: tar -czf workspace.tar.gz * .git - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: tar cabal + - name: tar cabal run: | cd ~/.cabal tar -czf cabal.tar.gz * - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Upload workspace + - name: Upload workspace uses: actions/upload-artifact@v2 with: name: workspace retention-days: 1 path: workspace.tar.gz - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Upload .cabal + - name: Upload .cabal uses: actions/upload-artifact@v2 with: name: cabal-home retention-days: 1 path: ~/.cabal/cabal.tar.gz - bench-example: - needs: [bench-init, pre_job] + bench_example: + needs: [bench_init, pre_job] runs-on: ${{ matrix.os }} strategy: @@ -111,47 +102,40 @@ jobs: example: ['cabal', 'lsp-types'] steps: - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - uses: haskell/actions/setup@v1 + - uses: haskell/actions/setup@v1 with: ghc-version: ${{ matrix.ghc }} cabal-version: '3.2' enable-stack: false - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Download cabal home + - name: Download cabal home uses: actions/download-artifact@v2 with: name: cabal-home path: . - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Download workspace + - name: Download workspace uses: actions/download-artifact@v2 with: name: workspace path: . - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: untar + - name: untar run: | mkdir -p ~/.cabal tar xzf workspace.tar.gz tar xzf cabal.tar.gz --directory ~/.cabal - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Bench + - name: Bench shell: bash run: cabal bench ghcide:benchHist -j --benchmark-options="${{ matrix.example }}" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Display results + - name: Display results shell: bash run: | column -s, -t < ghcide/bench-results/unprofiled/${{ matrix.example }}/results.csv | tee ghcide/bench-results/unprofiled/${{ matrix.example }}/results.txt - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Archive benchmarking artifacts + - name: Archive benchmarking artifacts uses: actions/upload-artifact@v2 with: name: bench-results-${{ runner.os }}-${{ matrix.ghc }} @@ -161,8 +145,7 @@ jobs: ghcide/bench-results/**/*.svg ghcide/bench-results/**/*.eventlog.html - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Archive benchmark logs + - name: Archive benchmark logs uses: actions/upload-artifact@v2 with: name: bench-logs-${{ runner.os }}-${{ matrix.ghc }} @@ -170,3 +153,16 @@ jobs: ghcide/bench-results/**/*.log ghcide/bench-results/**/*.eventlog ghcide/bench-results/**/*.hp + + post_job: + if: always() + runs-on: ubuntu-latest + needs: [pre_job, bench_init, bench_example] + steps: + - run: | + echo "jobs info: ${{ toJSON(needs) }}" + - if: contains(needs.*.result, 'failure') + run: exit 1 + - if: contains(needs.*.result, 'cancelled') + name: cancelling + uses: andymckay/cancel-action@0.2 diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml index 005506946d..dce5f9083b 100644 --- a/.github/workflows/nix.yml +++ b/.github/workflows/nix.yml @@ -28,6 +28,7 @@ jobs: # Enter the development shell and run `cabal build` develop: + if: needs.pre_job.outputs.should_skip_develop != 'true' needs: pre_job runs-on: ${{ matrix.os }} @@ -37,26 +38,22 @@ jobs: os: [ubuntu-latest, macOS-latest] steps: - - if: ${{ needs.pre_job.outputs.should_skip_develop != 'true' }} - uses: actions/checkout@v2 + - uses: actions/checkout@v2 with: submodules: true - - if: ${{ needs.pre_job.outputs.should_skip_develop != 'true' }} - uses: cachix/install-nix-action@v13 + - uses: cachix/install-nix-action@v13 with: install_url: https://nixos-nix-install-tests.cachix.org/serve/i6laym9jw3wg9mw6ncyrk6gjx4l34vvx/install install_options: '--tarball-url-prefix https://nixos-nix-install-tests.cachix.org/serve' extra_nix_config: | experimental-features = nix-command flakes nix_path: nixpkgs=channel:nixos-unstable - - if: ${{ needs.pre_job.outputs.should_skip_develop != 'true' }} - uses: cachix/cachix-action@v10 + - uses: cachix/cachix-action@v10 with: name: haskell-language-server # Disable pushing, we will do that in job `build` skipPush: true - - if: ${{ needs.pre_job.outputs.should_skip_develop != 'true' }} - run: | + - run: | nix develop --print-build-logs --command cabal update nix develop --print-build-logs --command cabal build @@ -66,10 +63,10 @@ jobs: # 2. Nix files are changed (runs on PR) build: needs: pre_job - runs-on: ${{ matrix.os }} + runs-on: matrix.os env: HAS_TOKEN: ${{ secrets.HLS_CACHIX_AUTH_TOKEN != '' }} - if: ${{ needs.pre_job.outputs.should_skip_build != 'true' || (github.repository_owner == 'haskell' && github.ref == 'refs/heads/master') }} + if: (needs.pre_job.outputs.should_skip_build != 'true' && needs.pre_job.outputs.should_skip_pr != 'true') || (github.repository_owner == 'haskell' && github.ref == 'refs/heads/master') strategy: fail-fast: false matrix: @@ -104,3 +101,16 @@ jobs: - name: Push binaries if: ${{ env.HAS_TOKEN == 'true' }} run: nix path-info --json | jq -r '.[].path' | cachix push haskell-language-server + + post_job: + if: always() + runs-on: ubuntu-latest + needs: [pre_job, develop, build] + steps: + - run: | + echo "jobs info: ${{ toJSON(needs) }}" + - if: contains(needs.*.result, 'failure') + run: exit 1 + - if: contains(needs.*.result, 'cancelled') + name: cancelling + uses: andymckay/cancel-action@0.2 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 428a035800..70145d7851 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,14 +20,21 @@ jobs: uses: fkirc/skip-duplicate-actions@v3.4.0 with: cancel_others: true - paths_ignore: '["**/docs/**", "**.md", "**/LICENSE", ".circleci/**", "install/**", "**.nix", "flake.lock", "**/README.md", "FUNDING.yml"]' + paths_ignore: '["**/docs/**", "**.md", "**/LICENSE", "install/**", "**.nix", "flake.lock", "**/README.md", "FUNDING.yml"]' # If we only change ghcide downstream packages we have not test ghcide itself - id: skip_ghcide_check uses: fkirc/skip-duplicate-actions@v3.4.0 with: paths_ignore: '["hls-test-utils/**", "plugins/**", "src/**", "exe/**", "test/**", "shake-bench/**"]' + - if: steps.skip_check.outputs.should_skip == 'true' + name: Skip circleci + uses: marocchino/sticky-pull-request-comment@v2 + with: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + message: We are gonna [skip circleci] test: + if: needs.pre_job.outputs.should_skip != 'true' needs: pre_job runs-on: ${{ matrix.os }} strategy: @@ -67,51 +74,47 @@ jobs: ghc: '8.8.4' steps: - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - uses: actions/checkout@v2 + - uses: actions/checkout@v2 with: submodules: true - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - uses: haskell/actions/setup@v1 + - uses: haskell/actions/setup@v1 with: ghc-version: ${{ matrix.ghc }} cabal-version: "3.4" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - run: ./fmt.sh + - run: ./fmt.sh name: "HLint via ./fmt.sh" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.os == 'windows-latest'}} + - if: matrix.os == 'windows-latest' name: Set some window specific things run: | echo "CABAL_STORE_DIR=$SYSTEMDRIVE\\SR" >> $GITHUB_ENV echo "CABAL_PKGS_DIR=~\\AppData\\cabal\\packages" >> $GITHUB_ENV - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.os != 'windows-latest'}} + - if: matrix.os != 'windows-latest' name: Set some linux/macOS specific things run: | echo "CABAL_STORE_DIR=~/.cabal/store" >> $GITHUB_ENV echo "CABAL_PKGS_DIR=~/.cabal/packages" >> $GITHUB_ENV - - name: Workaround for GHC 8.10.5 on macOS - if: matrix.os == 'macOS-latest' && matrix.ghc == '8.10.5' + - if: matrix.os == 'macOS-latest' && matrix.ghc == '8.10.5' + name: Workaround for GHC 8.10.5 on macOS run: | echo "# uninstalling CommandLineTools (see https://github.com/haskell/haskell-language-server/issues/1913#issuecomment-861667786)" sudo rm -rf /Library/Developer/CommandLineTools # Needs to be before Cache Cabal so the cache can detect changes to the modified cabal.project file - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.ghc == '9.0.1' }} + - if: matrix.ghc == '9.0.1' name: Use modified cabal.project for ghc9 run: cp cabal-ghc901.project cabal.project - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.ghc == '8.8.4' && matrix.os == 'windows-latest' }} + - if: matrix.ghc == '8.8.4' && matrix.os == 'windows-latest' name: Modify cabal.project to workaround segfaults for ghc-8.8.4 and windows run: | echo "package floskell" >> cabal.project echo " ghc-options: -O0" >> cabal.project - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Cache Cabal + - name: Cache Cabal uses: actions/cache@v2 env: cache-name: cache-cabal @@ -125,12 +128,10 @@ jobs: v2-${{ runner.os }}-${{ matrix.ghc }}-build- v2-${{ runner.os }}-${{ matrix.ghc }} - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - run: cabal update + - run: cabal update # Need this to work around filepath length limits in Windows - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Shorten binary names + - name: Shorten binary names run: | sed -i.bak -e 's/haskell-language-server/hls/g' \ -e 's/haskell_language_server/hls/g' \ @@ -138,26 +139,16 @@ jobs: sed -i.bak -e 's/Paths_haskell_language_server/Paths_hls/g' \ src/**/*.hs exe/*.hs - # this is only safe if the test environment is isolated - - name: setup ide cache - run: | - export XDG_CACHE_HOME=$RUNNER_TEMP/cache - rm -rf ~/.cache/ghcide - rm -rf ~/.cache/hie-bios - rm -rf $XDG_CACHE_HOME/ghcide - rm -rf $XDG_CACHE_HOME/hie-bios - - - if: ${{ needs.pre_job.outputs.should_skip != 'true' }} - name: Build + - name: Build # Retry it three times to workaround compiler segfaults in windows run: cabal build || cabal build || cabal build - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && needs.pre_job.outputs.should_skip_ghcide != 'true' && matrix.test }} + - if: needs.pre_job.outputs.should_skip_ghcide != 'true' && matrix.test name: Test ghcide # run the tests without parallelism to avoid running out of memory run: cabal test ghcide --test-options="-j1 --rerun-update" || cabal test ghcide --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test ghcide --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test && !(matrix.os == 'windows-latest' && matrix.ghc == '9.0.1')}} + - if: matrix.test && !(matrix.os == 'windows-latest' && matrix.ghc == '9.0.1') name: Test func-test suite env: HLS_TEST_EXE: hls @@ -167,7 +158,7 @@ jobs: # instances to be spun up for the poor github actions runner to handle run: cabal test func-test --test-options="-j1 --rerun --rerun-update" || cabal test func-test --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test func-test --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test wrapper-test suite env: HLS_TEST_EXE: hls @@ -177,54 +168,67 @@ jobs: # instances to be spun up for the poor github actions runner to handle run: cabal test wrapper-test --test-options="-j1" || cabal test wrapper-test --test-options="-j1" || cabal test wrapper-test --test-options="-j1" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test && matrix.ghc != '9.0.1' }} + - if: matrix.test && matrix.ghc != '9.0.1' name: Test hls-brittany-plugin run: cabal test hls-brittany-plugin --test-options="-j1 --rerun-update" || cabal test hls-brittany-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-brittany-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test && matrix.ghc != '9.0.1' }} + - if: matrix.test && matrix.ghc != '9.0.1' name: Test hls-class-plugin run: cabal test hls-class-plugin --test-options="-j1 --rerun-update" || cabal test hls-class-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-class-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test hls-eval-plugin run: cabal test hls-eval-plugin --test-options="-j1 --rerun-update" || cabal test hls-eval-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-eval-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test hls-haddock-comments-plugin run: cabal test hls-haddock-comments-plugin --test-options="-j1 --rerun-update" || cabal test hls-haddock-comments-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-haddock-comments-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test hls-splice-plugin run: cabal test hls-splice-plugin --test-options="-j1 --rerun-update" || cabal test hls-splice-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-splice-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test && matrix.ghc != '9.0.1' }} + - if: matrix.test && matrix.ghc != '9.0.1' name: Test hls-stylish-haskell-plugin run: cabal test hls-stylish-haskell-plugin --test-options="-j1 --rerun-update" || cabal test hls-stylish-haskell-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-stylish-haskell-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test hls-ormolu-plugin run: cabal test hls-ormolu-plugin --test-options="-j1 --rerun-update" || cabal test hls-ormolu-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-ormolu-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test hls-fourmolu-plugin run: cabal test hls-fourmolu-plugin --test-options="-j1 --rerun-update" || cabal test hls-fourmolu-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-fourmolu-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test && matrix.ghc != '9.0.1' }} + - if: matrix.test && matrix.ghc != '9.0.1' name: Test hls-tactics-plugin test suite run: cabal test hls-tactics-plugin --test-options="-j1 --rerun-update" || cabal test hls-tactics-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-tactics-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }} + - if: matrix.test name: Test hls-refine-imports-plugin test suite run: cabal test hls-refine-imports-plugin --test-options="-j1 --rerun-update" || cabal test hls-refine-imports-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-refine-imports-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test}} + - if: matrix.test name: Test hls-call-hierarchy-plugin test suite run: cabal test hls-call-hierarchy-plugin --test-options="-j1 --rerun-update" || cabal test hls-call-hierarchy-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-call-hierarchy-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test}} + - if: matrix.test name: Test hls-rename-plugin test suite run: cabal test hls-rename-plugin --test-options="-j1 --rerun-update" || cabal test hls-rename-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-rename-plugin --test-options="-j1 --rerun" - - if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test}} + - if: matrix.test name: Test hls-hlint-plugin test suite run: cabal test hls-hlint-plugin --test-options="-j1 --rerun-update" || cabal test hls-hlint-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-hlint-plugin --test-options="-j1 --rerun" + + post_job: + if: always() + runs-on: ubuntu-latest + needs: [pre_job, test] + steps: + - run: | + echo "jobs info: ${{ toJSON(needs) }}" + - if: contains(needs.*.result, 'failure') + run: exit 1 + - if: contains(needs.*.result, 'cancelled') + name: cancelling + uses: andymckay/cancel-action@0.2