Skip to content

Commit

Permalink
ci: Update haskell-ci.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
maoe committed Mar 12, 2021
1 parent 1beafea commit 4a7cad3
Showing 1 changed file with 20 additions and 18 deletions.
38 changes: 20 additions & 18 deletions .github/workflows/haskell-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
#
# For more information, see https://github.com/haskell-CI/haskell-ci
#
# version: 0.11.20210218
# version: 0.11.20210222
#
# REGENDATA ("0.11.20210218",["github","influxdb.cabal"])
# REGENDATA ("0.11.20210222",["github","influxdb.cabal"])
#
name: Haskell-CI
on:
Expand All @@ -28,7 +28,7 @@ jobs:
include:
- ghc: 9.0.1
allow-failure: false
- ghc: 8.10.3
- ghc: 8.10.4
allow-failure: false
- ghc: 8.8.4
allow-failure: false
Expand All @@ -38,17 +38,13 @@ jobs:
allow-failure: false
fail-fast: false
steps:
- name: Set up InfluxDB
- name: apt
run: |
wget https://dl.influxdata.com/influxdb/releases/influxdb_${INFLUXDB_VERSION}_amd64.deb
dpkg -x influxdb_${INFLUXDB_VERSION}_amd64.deb influxdb
./influxdb/usr/bin/influxd &
- name: Set up GHC
id: setup-haskell-cabal
uses: haskell/actions/setup@v1
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: latest
apt-get update
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common
apt-add-repository -y 'ppa:hvr/ghc'
apt-get update
apt-get install -y ghc-$GHC_VERSION cabal-install-3.4
env:
GHC_VERSION: ${{ matrix.ghc }}
- name: Set PATH and environment variables
Expand All @@ -57,20 +53,26 @@ jobs:
echo "LANG=C.UTF-8" >> $GITHUB_ENV
echo "CABAL_DIR=$HOME/.cabal" >> $GITHUB_ENV
echo "CABAL_CONFIG=$HOME/.cabal/config" >> $GITHUB_ENV
HC=${{ steps.setup-haskell-cabal.outputs.ghc-exe }}
HC=/opt/ghc/$GHC_VERSION/bin/ghc
echo "HC=$HC" >> $GITHUB_ENV
echo "HCPKG=${{ steps.setup-haskell-cabal.outputs.ghc-path }}/ghc-pkg" >> $GITHUB_ENV
echo "HADDOCK=${{ steps.setup-haskell-cabal.outputs.ghc-path }}/haddock" >> $GITHUB_ENV
echo "CABAL=${{ steps.setup-haskell-cabal.outputs.cabal-exe }} -vnormal+nowrap" >> $GITHUB_ENV
echo "HCPKG=/opt/ghc/$GHC_VERSION/bin/ghc-pkg" >> $GITHUB_ENV
echo "HADDOCK=/opt/ghc/$GHC_VERSION/bin/haddock" >> $GITHUB_ENV
echo "CABAL=/opt/cabal/3.4/bin/cabal -vnormal+nowrap" >> $GITHUB_ENV
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
echo "HCNUMVER=$HCNUMVER" >> $GITHUB_ENV
echo "ARG_TESTS=--enable-tests" >> $GITHUB_ENV
echo "ARG_BENCH=--enable-benchmarks" >> $GITHUB_ENV
echo "HEADHACKAGE=false" >> $GITHUB_ENV
echo "ARG_COMPILER=--ghc --with-compiler=${{ steps.setup-haskell-cabal.outputs.ghc-exe }}" >> $GITHUB_ENV
echo "ARG_COMPILER=--ghc --with-compiler=$HC" >> $GITHUB_ENV
echo "GHCJSARITH=0" >> $GITHUB_ENV
env:
GHC_VERSION: ${{ matrix.ghc }}
- name: Set up InfluxDB
run: |
wget -q https://dl.influxdata.com/influxdb/releases/influxdb_${INFLUXDB_VERSION}_amd64.deb
dpkg -x influxdb_${INFLUXDB_VERSION}_amd64.deb influxdb
./influxdb/usr/bin/influxd config
./influxdb/usr/bin/influxd &
- name: env
run: |
env
Expand Down

0 comments on commit 4a7cad3

Please sign in to comment.