mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-04-20 13:22:04 +02:00
convery release workflow to matrix
This commit is contained in:
parent
f098864572
commit
bf93f7572f
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -5,7 +5,7 @@ on:
|
||||
- pull_request
|
||||
|
||||
jobs:
|
||||
test:
|
||||
ci:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
|
30
.github/workflows/release.yml
vendored
30
.github/workflows/release.yml
vendored
@ -6,8 +6,13 @@ on:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
latest:
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
channel:
|
||||
- dev
|
||||
- latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
@ -28,6 +33,7 @@ jobs:
|
||||
|
||||
# https://github.com/changesets/action
|
||||
- name: Create release pull request
|
||||
if: matrix.channel == 'latest'
|
||||
uses: changesets/action@master
|
||||
with:
|
||||
publish: yarn changeset publish
|
||||
@ -36,27 +42,9 @@ jobs:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
|
||||
dev:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Setup node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 12.x
|
||||
registry-url: https://registry.npmjs.org
|
||||
|
||||
- name: Install dependencies
|
||||
run: yarn
|
||||
|
||||
- name: Prepare release
|
||||
run: yarn prerelease
|
||||
|
||||
# https://github.com/atlassian/changesets/blob/master/docs/snapshot-releases.md
|
||||
- name: Release to @dev channel
|
||||
if: matrix.channel == 'dev'
|
||||
run: |
|
||||
yarn changeset version --snapshot
|
||||
yarn changeset publish --tag dev
|
||||
|
Loading…
x
Reference in New Issue
Block a user