chore: fix push branches CI #2
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: Push checks | |
on: | |
push: | |
branches: | |
- master | |
- beta | |
jobs: | |
release-device-manager: | |
name: Release process | |
runs-on: ubuntu-20.04 | |
permissions: | |
contents: write | |
issues: write | |
pull-requests: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: "lts/*" | |
registry-url: "https://registry.npmjs.org" | |
- name: Install dependencies | |
run: npm ci | |
- name: Build | |
run: npm run build | |
- name: Release | |
env: | |
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} | |
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SEMANTIC_RELEASE_NPM_PUBLISH: "true" | |
SEMANTIC_RELEASE_SLACK_WEBHOOK: ${{ secrets.SEMANTIC_RELEASE_SLACK_WEBHOOK }} | |
run: npx semantic-release | |
release-types: | |
name: Release process | |
runs-on: ubuntu-20.04 | |
permissions: | |
contents: write | |
issues: write | |
pull-requests: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: "lts/*" | |
registry-url: "https://registry.npmjs.org" | |
- name: Go to types directory | |
run: cd types | |
- name: Install dependencies | |
run: npm ci | |
- name: Release | |
env: | |
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} | |
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SEMANTIC_RELEASE_NPM_PUBLISH: "true" | |
SEMANTIC_RELEASE_SLACK_WEBHOOK: ${{ secrets.SEMANTIC_RELEASE_SLACK_WEBHOOK }} | |
run: npx semantic-release | |
documentation_deploy: | |
needs: [release-device-manager, release-types] | |
name: Documentation - Deploy | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.ACCESS_TOKEN }} | |
- uses: convictional/trigger-workflow-and-wait@v1.6.3 | |
with: | |
owner: kuzzleio | |
repo: documentation | |
github_token: ${{ secrets.ACCESS_TOKEN_CI }} | |
workflow_file_name: child_repo.workflow.yml | |
ref: ${{ github.ref_name == 'master' && 'master' || 'develop' }} | |
client_payload: '{"repo_name":"kuzzle-plugin-device-manager","branch":"${{ github.ref_name }}","version":"1"}' |