Skip to content

Commit

Permalink
Add GitHub action
Browse files Browse the repository at this point in the history
  • Loading branch information
102747419 committed Sep 21, 2024
1 parent 6ab2338 commit 0e3c037
Show file tree
Hide file tree
Showing 4 changed files with 3,073 additions and 1 deletion.
44 changes: 44 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Deploy PressKit.io to GitHub Pages

on:
push:
branches:
- master

workflow_dispatch:

jobs:
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Node.js environment
uses: actions/setup-node@v4
with:
node-version: "18"
cache: "npm"

- name: Run install
uses: borales/actions-yarn@v4
with:
cmd: install

- name: Build PressKit.io site
run: yarn run build

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

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: "./build"

- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
build/
node_modules
build/
Loading

0 comments on commit 0e3c037

Please sign in to comment.