Skip to content

ci: add contents write permission #75

ci: add contents write permission

ci: add contents write permission #75

Workflow file for this run

name: Continuos Integration
on:
push:
workflow_dispatch:
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20
- name: install
run: npm ci
- name: eslint
run: npm run lint
- name: build
run: npm run build
test_unit:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20
- name: install
run: npm ci
- name: test
run: npm run test
test_visual:
name: Visual
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20
- name: Install dependencies
run: npm ci
- name: Install Playwright Browsers
run: npx playwright install --with-deps
- name: Run Playwright tests
run: npx playwright test
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: playwright-report/
retention-days: 30
publish:
name: Publish
timeout-minutes: 2
runs-on: ubuntu-latest
permissions:
packages: write
repository-projects: write
contents: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 20
- name: Install dependencies
run: npm ci
- name: Publish
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
needs: [test_unit, test_visual, build]
if: github.ref_name == 'main'