Update jupyterlab-ihaskell for 4.x (#1426) #335
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker | |
on: | |
push: | |
branches: | |
paths: | |
- '.dockerignore' | |
- '.github/workflows/docker.yml' | |
- 'Dockerfile' | |
- 'LICENSE' | |
- 'ghc-parser/**' | |
- 'html/**' | |
- 'ihaskell-display/**' | |
- 'ihaskell.cabal' | |
- 'ipython-kernel/**' | |
- 'jupyterlab-ihaskell/**' | |
- 'main/**' | |
- 'src/**' | |
- 'stack.yaml' | |
pull_request: | |
paths: | |
- '.dockerignore' | |
- '.github/workflows/docker.yml' | |
- 'Dockerfile' | |
- 'LICENSE' | |
- 'ghc-parser/**' | |
- 'html/**' | |
- 'ihaskell-display/**' | |
- 'ihaskell.cabal' | |
- 'ipython-kernel/**' | |
- 'jupyterlab-ihaskell/**' | |
- 'main/**' | |
- 'src/**' | |
- 'stack.yaml' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: haskell/actions/setup@v2 | |
name: Setup Haskell Stack | |
with: | |
enable-stack: true | |
stack-version: "latest" | |
- name: Check Dockerfile GHC version matches | |
run: | | |
set -e | |
STACK_GHC_VERSION=$(stack exec -- ghc --version | awk '{ print $NF }') | |
DOCKER_GHC_VERSION=$(sed -n 's/ARG GHC_VERSION=\(.*\)/\1/p' Dockerfile) | |
if [[ ${STACK_GHC_VERSION} != ${DOCKER_GHC_VERSION} ]]; then | |
echo 'GHC_VERSION in Dockerfile does not match stack resolver' | |
echo "GHC_VERSION should be ${STACK_GHC_VERSION}" | |
exit 1 | |
fi | |
- uses: elgohr/Publish-Docker-Github-Action@v5 | |
with: | |
name: gibiansky/ihaskell | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
snapshot: true | |
no_push: ${{ github.event_name == 'pull_request' }} |