ci: revert

This commit is contained in:
Viren070
2024-10-12 15:06:48 +01:00
parent c248e6ead5
commit ccca44f28c
2 changed files with 26 additions and 13 deletions
+25 -13
View File
@@ -3,7 +3,7 @@ name: Build and Deploy to GitHub Pages
on:
push:
branches:
- "**" # Trigger on all branches
- main
# Review gh actions docs if you want to further define triggers, paths, etc
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
@@ -24,16 +24,28 @@ jobs:
run: npm ci
- name: Build website
run: npm run build
- name: Create build directory
run: mkdir -p ./build/${{ github.head_ref || github.ref_name }}
- name: Deploy to GitHub Pages
if: github.actor != 'dependabot[bot]'
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
destination_dir: ${{ github.head_ref || github.ref_name }}
allow_empty_commit: true
- name: Upload Build Artifact
uses: actions/upload-pages-artifact@v3
with:
path: build
deploy:
name: Deploy to GitHub Pages
needs: build
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
pages: write # to deploy to Pages
id-token: write # to verify the deployment originates from an appropriate source
# Deploy to the github-pages environment
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
+1
View File
@@ -0,0 +1 @@
guides.viren070.me