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
41 changes: 41 additions & 0 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Pages

# Renders the Quarto site in docs/ (the project page and the arXiv-style
# article, HTML and PDF) and publishes it to the gh-pages branch, which
# GitHub Pages serves at https://elearninghub.github.io/academic-project-template/.
on:
push:
branches: [main]
workflow_dispatch:

permissions:
contents: write

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

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: prefix-dev/setup-pixi@v0.8.1
with:
pixi-version: v0.72.2
cache: true

# The fontawesome, revealjs-clean and arxiv extensions, and TinyTeX for the PDF.
- name: Quarto extensions and TinyTeX
run: pixi run install-quarto-extensions

- name: Render
run: pixi run docs

- name: Publish to gh-pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/_output
force_orphan: true
7 changes: 7 additions & 0 deletions docs/_quarto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@
project:
title: "Docs"
output-dir: "_output"
# The project page and the article. The other .md files here are Sphinx
# sources (Read the Docs) and use MyST syntax Quarto can't render.
render:
- project-page/index.md
- arxiv-article/arxiv-article.qmd
resources:
- index.html

# options for all formats - suggested not to change
from: markdown+raw_attribute+raw_tex
Expand Down
4 changes: 0 additions & 4 deletions docs/arxiv-article/_publish.yml

This file was deleted.

2 changes: 2 additions & 0 deletions docs/arxiv-article/arxiv-article.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
title: "Demo arXiv template"
format:
arxiv-pdf:
# LuaLaTeX finds Latin Modern in the TeX tree; XeLaTeX looks only at system fonts.
pdf-engine: lualatex
keep-tex: true
linenumbers: false
doublespacing: false
Expand Down
12 changes: 12 additions & 0 deletions docs/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Academic project template</title>
<meta http-equiv="refresh" content="0; url=project-page/">
<link rel="canonical" href="project-page/">
</head>
<body>
<p><a href="project-page/">The project page</a> · <a href="arxiv-article/arxiv-article.html">the article</a> (<a href="arxiv-article/arxiv-article.pdf">PDF</a>)</p>
</body>
</html>
21 changes: 11 additions & 10 deletions docs/project-page/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,26 @@ css:
- https://cdn.jsdelivr.net/npm/bulma-slider@2.0.0/dist/css/bulma-slider.min.css
- https://cdn.jsdelivr.net/gh/jpswalsh/academicons@1/css/academicons.min.css
- ./css/index.css
# Served as separate files: embedding the 50 MB of video made one 61 MB page.
self-contained: false
embed-resources: false
resources:
- css/
- js/
- images/
- videos/
- interpolation/
include-in-header:
- text: |
<script async src="https://www.googletagmanager.com/gtag/js?id=G-PYVRSFMDRL"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-PYVRSFMDRL');
</script>
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bulma-carousel@4.0.4/dist/js/bulma-carousel.min.js"></script>
<script>
console.log('bulmaCarousel is:', typeof bulmaCarousel); // Should log 'function' or 'object'
</script>
<script src="./js/index.js"></script>
---

::: {.notification .is-warning .is-light .has-text-centered}
**Template demo.** This page shows what the [academic project template](https://github.com/eLearningHub/academic-project-template) produces, filled with the content of [Nerfies](https://nerfies.github.io/) (Park et al., ICCV 2021), whose project page the template adapts. Replace it with your own paper.
:::

::: {.hero}
::: {.hero-body}
::: {.container .is-max-desktop}
Expand Down
8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ pip install pytest pytest-cov pytest-mock black isort flake8 mypy bandit safety
"""
install-quarto-extensions = '''
cd docs;
quarto add quarto-ext/fontawesome;
quarto install extension grantmcdermott/quarto-revealjs-clean;
quarto install extension mikemahoney218/quarto-arxiv;
quarto install tinytex;
quarto add --no-prompt quarto-ext/fontawesome;
quarto add --no-prompt grantmcdermott/quarto-revealjs-clean;
quarto add --no-prompt mikemahoney218/quarto-arxiv;
quarto install --no-prompt tinytex;
'''
sdocs = "python -m pip install -e . && cd docs && python -m sphinx -b html . _build"

Expand Down
Loading