Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add release workflow #21

Merged
merged 2 commits into from Aug 3, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
49 changes: 49 additions & 0 deletions .github/workflows/release.yml
@@ -0,0 +1,49 @@
name: Binaryen.ml Release w/ Archive
on:
push:
tags:
- '*'

jobs:
build:
name: Create Release
runs-on: macos-latest
steps:
- name: Install git-archive-all
run: |
brew install git-archive-all

- uses: olegtarasov/get-tag@v2
id: tag_name

- name: Checkout code
uses: actions/checkout@v2

- name: Build archive
run: |
git-archive-all --force-submodules binaryen-archive.tar.gz

- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ steps.tag_name.outputs.tag }}
body: |
Changes in this Release
- FILL OUT CHANGES HERE
draft: true
prerelease: ${{ !startsWith(steps.tag_name.outputs.tag, 'v') }}

- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./binaryen-archive.tar.gz
asset_name: binaryen-archive-${{ steps.tag_name.outputs.tag }}.tar.gz
asset_content_type: application/gzip