Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add publishing to pages #297

Merged
merged 1 commit into from
Nov 6, 2024
Merged
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
32 changes: 27 additions & 5 deletions .github/workflows/html-build.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
name: Rebuild all with asciidoctor

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

on:
push:
Expand All @@ -13,6 +16,11 @@ on:
branches:
- main

# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true

jobs:
# Build job
build:
Expand All @@ -28,9 +36,23 @@ jobs:
run: |
find . -name "*.asciidoc" -exec touch {} \;
make all
- name: Upload Artifact
uses: actions/upload-artifact@v4
if: always()
find . -type d -exec mkdir -p ../_site/{} \;
find . -name "*.html" -exec cp {} ../_site/{} \;
find ../_site -type d -empty -delete
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
name: HTML
path: ${{github.workspace}}/**/*.html
path: ../_site

# Deployment job
deploy:
if: ${{ github.event_name == 'push'}}
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4