uniswap-interface-uncensored/.github/workflows/release.yaml

53 lines
1.4 KiB
YAML
Raw Normal View History

2019-12-12 01:45:31 +03:00
on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*'
name: Build and Release
jobs:
build:
2019-12-12 02:57:06 +03:00
name: Global Job
2019-12-12 01:45:31 +03:00
strategy:
matrix:
node: ['10.x']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@master
2019-12-12 18:34:28 +03:00
- name: Create production build
uses: actions/setup-node@master
2019-12-12 01:45:31 +03:00
with:
node-version: ${{ matrix.node }}
- run: npm install -g yarn
- run: yarn
- run: yarn build
2019-12-12 02:57:06 +03:00
env:
REACT_APP_NETWORK_ID: ${{ secrets.REACT_APP_NETWORK_ID }}
2019-12-12 01:45:31 +03:00
- 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: false
- name: Zip the build
uses: thedoctor0/zip-release@master
with:
filename: 'build.zip'
path: './build'
exclusions: 'x'
- name: Upload Build
id: build-asset
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
2019-12-12 18:34:28 +03:00
upload_url: ${{ steps.create_release.outputs.upload_url }}
2019-12-12 01:45:31 +03:00
asset_path: build.zip
asset_name: build.zip
asset_content_type: application/zip