mirror of
https://github.com/morris/vanilla-todo.git
synced 2025-01-17 12:48:15 +01:00
add deployment to github pages
This commit is contained in:
parent
d592febdeb
commit
f38899e46d
22
.github/workflows/checks.yml
vendored
22
.github/workflows/checks.yml
vendored
@ -1,22 +0,0 @@
|
||||
name: Checks
|
||||
|
||||
on: push
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Use Node.js 20
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20
|
||||
- run: npm ci
|
||||
- run: npm run format-check
|
||||
- run: npm run lint
|
||||
- run: npm run lint-styles
|
||||
- run: npm run dev &
|
||||
- run: npx playwright install --with-deps
|
||||
- run: npm run test-coverage
|
||||
env:
|
||||
CI: true
|
42
.github/workflows/pipeline.yml
vendored
Normal file
42
.github/workflows/pipeline.yml
vendored
Normal file
@ -0,0 +1,42 @@
|
||||
name: Pipeline
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ['main']
|
||||
|
||||
jobs:
|
||||
checks:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20
|
||||
- run: npm ci
|
||||
- run: npm run format-check
|
||||
- run: npm run lint
|
||||
- run: npm run lint-styles
|
||||
- run: npm run dev &
|
||||
- run: npx playwright install --with-deps
|
||||
- run: npm run test-coverage
|
||||
env:
|
||||
CI: true
|
||||
deploy:
|
||||
needs: checks
|
||||
permissions:
|
||||
pages: write
|
||||
id-token: write
|
||||
concurrency:
|
||||
group: pages
|
||||
cancel-in-progress: false
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/configure-pages@v3
|
||||
- uses: actions/upload-pages-artifact@v2
|
||||
with:
|
||||
path: public
|
||||
- id: deployment
|
||||
uses: actions/deploy-pages@v2
|
Loading…
x
Reference in New Issue
Block a user