Skip to content

Commit

Permalink
different deployment strategy
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Azpillaga Aldalur committed Nov 29, 2023
1 parent a798935 commit 2372e89
Showing 1 changed file with 19 additions and 8 deletions.
27 changes: 19 additions & 8 deletions .github/workflows/onpush.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,24 @@ name: Build and Deploy to GitHub Pages

on: push

permissions:
contents: read
pages: write
id-token: write

jobs:
build:
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Setup Pages
uses: actions/configure-pages@v3

- name: Set up Node.js
uses: actions/setup-node@v4
with:
Expand All @@ -20,10 +30,11 @@ jobs:

- name: Test project
run: npm test

- name: Deploy to GitHub Pages
uses: JamesIves/github-pages-deploy-action@releases/v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages
folder: dist
path: 'dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2

0 comments on commit 2372e89

Please sign in to comment.