Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
16 changes: 11 additions & 5 deletions .github/workflows/linkcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,21 @@ jobs:
permissions:
issues: write # required for QuantEcon link-checker
steps:
# Checkout the live site (html)
- name: Checkout
uses: actions/checkout@v6
# Download the latest deployed site artifact
- name: Download latest Pages artifact
uses: dawidd6/action-download-artifact@v19
with:
ref: gh-pages
workflow: publish.yml
name: github-pages
path: _site_artifact
Comment thread
mmcky marked this conversation as resolved.
Outdated
- name: Extract Pages artifact
run: |
mkdir -p _site
tar -xf _site_artifact/artifact.tar -C _site
Comment thread
mmcky marked this conversation as resolved.
Outdated
- name: AI-Powered Link Checker
uses: QuantEcon/action-link-checker@main
with:
html-path: '.' # gh-pages live html
html-path: '_site'
fail-on-broken: 'false'
silent-codes: '403,503'
ai-suggestions: 'true'
Expand Down
28 changes: 23 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,23 @@ on:
push:
tags:
- 'publish*'

permissions:
contents: write
Comment thread
mmcky marked this conversation as resolved.
pages: write
id-token: write

concurrency:
group: "pages"
cancel-in-progress: false

jobs:
publish:
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
runs-on: "runs-on=${{ github.run_id }}/family=g4dn.2xlarge/image=quantecon_ubuntu2404/disk=large"
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Checkout
uses: actions/checkout@v6
Expand Down Expand Up @@ -113,12 +126,17 @@ jobs:
html-manifest.json
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Deploy website to gh-pages
uses: peaceiris/actions-gh-pages@v4
- name: Add CNAME for custom domain
run: echo "python-programming.quantecon.org" > _build/html/CNAME
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: _build/html/
cname: python-programming.quantecon.org
path: _build/html/
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
- name: Prepare lecture-python-programming.notebooks sync
shell: bash -l {0}
run: |
Expand Down
Loading