Skip to content

Commit

Permalink
Fix deployment (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
amrabed authored Oct 20, 2024
1 parent aa09178 commit b8a648c
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
name: Deploy to GitHub Pages
name: Deploy to Pages

on:
pull_request:
types: [closed]
branches: [main]
push:
branches: ["main"]
workflow_dispatch:

permissions:
contents: read
Expand All @@ -17,7 +18,6 @@ jobs:
check:
uses: ./.github/workflows/check.yml
build:
if: github.event.pull_request.merged == true
needs: [check]
runs-on: ubuntu-latest
steps:
Expand All @@ -26,29 +26,25 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: 20
- name: Setup GitHuib Pages
- name: Setup GitHub Pages
uses: actions/configure-pages@v5
with:
static_site_generator: next
- name: Install dependencies
run: make install

- name: Build with Next.js
run: make build
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./out

deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

runs-on: ubuntu-latest
needs: build

steps:
- name: Publish to GitHub Pages
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit b8a648c

Please sign in to comment.