Version Packages (#103) #135
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish packages | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build-test-and-publish: | |
runs-on: ubuntu-latest | |
env: | |
DEV_CRYSTALLIZE_ACCESS_TOKEN_ID: | |
${{ secrets.DEV_CRYSTALLIZE_ACCESS_TOKEN_ID }} | |
DEV_CRYSTALLIZE_ACCESS_TOKEN_SECRET: | |
${{ secrets.DEV_CRYSTALLIZE_ACCESS_TOKEN_SECRET }} | |
strategy: | |
matrix: | |
node-version: [18.x] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v1 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- run: npm install | |
- run: npm run build | |
- run: npm test | |
- name: Create Release Pull Request or Publish to npm | |
id: changesets | |
uses: changesets/action@v1 | |
with: | |
publish: npm run publish-packages | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |