Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 19 additions & 4 deletions .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,20 @@ concurrency:
cancel-in-progress: true

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

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'

- name: Install dependencies
run: npm ci

# Injects an inline <script> that sets window.POLLINATIONS_TOKEN
- name: Inject Pollinations token into index.html
if: ${{ secrets.POLLINATIONS_TOKEN != '' }}
Expand All @@ -37,6 +42,9 @@ jobs:
mv index.html.tmp index.html
fi

- name: Run application verification tests
run: npm test

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

Expand All @@ -45,6 +53,13 @@ jobs:
with:
path: .

deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
Loading