Update and rename haskell.yml to build_binary.yml

This commit is contained in:
Teguh Hofstee 2019-11-02 19:51:43 -07:00 committed by GitHub
parent eebe41427e
commit b4560c7e8e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 38 additions and 0 deletions

38
.github/workflows/build_binary.yml vendored Normal file
View File

@ -0,0 +1,38 @@
name: Haskell CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Install dependencies
run: |
curl -sSL https://get.haskellstack.org/ | sh
- name: Build
run: |
make
zip --junk-paths sv2v ./bin/sv2v
- name: Create Release
id: create_release
uses: actions/create-release@v1.0.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: true
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./sv2v.zip
asset_name: sv2v.zip
asset_content_type: application/zip