Skip to content

fix test ubuntu-latest tets runner #296

fix test ubuntu-latest tets runner

fix test ubuntu-latest tets runner #296

Workflow file for this run

on:
push:
branches:
- "develop"
name: Release develop branch
jobs:
remove-old-release:
runs-on: ubuntu-latest
steps:
- name: remove assets
uses: mknejp/delete-release-assets@v1
with:
token: ${{ github.token }}
tag: latest
assets: '*'
fail-if-no-assets: false
fail-if-no-release: false
- name: remove old release
uses: cb80/delrel@latest
with:
tag: latest
build-all-platforms:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
name: Decker latest (${{ matrix.os }})
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: develop
- name: Cache dependencies
uses: actions/cache@v3
with:
path: ~/.stack
key: ${{ runner.os }}-${{ hashFiles('stack.yaml') }}
restore-keys: |
${{ runner.os }}-
- name: Install bzip2 with dev headers
run: sudo apt-get update && sudo apt-get install -y bzip2 libbz2-dev
- name: Setup Haskell
uses: haskell-actions/setup@v2
with:
enable-stack: true
stack-no-global: true
stack-version: latest
stack-setup-ghc: true
- name: Build & test
run: |
stack test
stack --local-bin-path=dist install
- name: Rename executable
if: ${{ matrix.os != 'windows-latest' }}
run: |
mv dist/decker "dist/decker-latest-${{ runner.os }}-${{ runner.arch }}-${{ github.sha }}"
- name: Rename executable
if: ${{ matrix.os == 'windows-latest' }}
run: |
mv dist/decker.exe "dist/decker-latest-${{ runner.os }}-${{ runner.arch }}-${{ github.sha }}.exe"
- name: Release
uses: "softprops/action-gh-release@v1"
with:
token: ${{ github.token }}
name: latest
tag_name: latest
target_commitish: develop
draft: false
prerelease: true
files: |
readme.md
changelog.md
dist/**