Skip to content

Add "View source data on GitHub" button to site header#4

Draft
Copilot wants to merge 2 commits intomainfrom
copilot/add-view-source-data-button
Draft

Add "View source data on GitHub" button to site header#4
Copilot wants to merge 2 commits intomainfrom
copilot/add-view-source-data-button

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 16, 2026

The GitHub Pages publication site had no link back to the source repository.

Changes

  • New --repo-url CLI arg (csv_to_html.py): optional; when provided, renders a "View source data on GitHub" anchor in the page header. Omitting it hides the button entirely (backward compatible).
  • GitHub icon + styling: inline SVG octicon, .gh-source-btn CSS class matching the existing button style, placed as a flex sibling of the title block in the header (justify-content: space-between pushes it to the top-right).
  • Workflow updated: deploy-pages.yml passes --repo-url "https://github.com/avc-adelaide/wspr-publications".
- name: Build static site
  run: |
    python scripts/csv_to_html.py \
      --title "WSPR Publications" \
      --scholar-user-id kxCnpPEAAAAJ \
      --repo-url "https://github.com/avc-adelaide/wspr-publications" \
      ...

URL is HTML-escaped before insertion into the href attribute.


💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

Co-authored-by: wspr <8169+wspr@users.noreply.github.com>
Copilot AI changed the title [WIP] Add 'View source data on GitHub' button to pages site Add "View source data on GitHub" button to site header Mar 16, 2026
Copilot AI requested a review from wspr March 16, 2026 01:44
Copilot finished work on behalf of wspr March 16, 2026 01:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants