Skip to content

Merge pull request #12 from TLDMain/master #28

Merge pull request #12 from TLDMain/master

Merge pull request #12 from TLDMain/master #28

Workflow file for this run

name: build
on:
push:
branches:
- master
- beta
pull_request:
branches:
- master
- beta
env:
YARN_CACHE: 001
jobs:
# test:
# timeout-minutes: 10
# runs-on: ubuntu-latest
# strategy:
# matrix:
# node-version: [10, 12, 14]
# steps:
# - uses: actions/checkout@v2
# with:
# fetch-depth: 0 # Required to retrieve git history
# - name: Use Node.js ${{ matrix.node-version }}
# uses: actions/setup-node@v2-beta
# with:
# node-version: ${{ matrix.node-version }}
# - name: Get yarn cache directory path
# id: yarn-cache-dir-path
# run: echo "::set-output name=dir::$(yarn cache dir)"
# - name: Cache node modules
# uses: actions/cache@v2
# id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
# with:
# path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
# key: ${{ runner.os }}-build-${{ env.YARN_CACHE }}-${{ hashFiles('**/yarn.lock') }}
# - run: yarn
release:
timeout-minutes: 10
if: github.event_name == 'push'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # Required to retrieve git history
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2-beta
with:
node-version: 14
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Cache node modules
uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-build-${{ env.YARN_CACHE }}-${{ hashFiles('**/yarn.lock') }}
- run: yarn
- name: Build assets
run: yarn build
- name: Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: yarn semantic-release