Skip to content

Commit

Permalink
Setup GHA
Browse files Browse the repository at this point in the history
  • Loading branch information
kazuyanagimoto committed Dec 2, 2024
1 parent 5d34c96 commit dbb06eb
Show file tree
Hide file tree
Showing 32 changed files with 3,731 additions and 18 deletions.
1 change: 1 addition & 0 deletions .Rprofile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
source("renv/activate.R")
41 changes: 41 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
on:
workflow_dispatch:
push:
branches: main

name: Quarto Publish
env:
RENV_PATHS_ROOT: ~/.cache/R/renv

jobs:
build-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out repository
uses: actions/checkout@v4

- name: Set up Quarto
uses: quarto-dev/quarto-actions/setup@v2

- name: Cache packages
uses: actions/cache@v1
with:
path: ${{ env.RENV_PATHS_ROOT }}
key: ${{ runner.os }}-renv-${{ hashFiles('**/renv.lock') }}
restore-keys: |
${{ runner.os }}-renv-
- name: Restore packages
shell: Rscript {0}
run: |
if (!requireNamespace("renv", quietly = TRUE)) install.packages("renv")
renv::restore()
- name: Render and Publish
uses: quarto-dev/quarto-actions/publish@v2
with:
target: gh-pages
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,8 @@
/.luarc.json
/template.typ
README.html
README_files/*
.Rproj.user
docs/
*_files/

/.quarto/
13 changes: 13 additions & 0 deletions .quartoignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
_quarto.yml
docs/
*.Rproj
static/fonts/
static/img/template-full.png
static/img/thumbnail.png
static/img/thumbnail.svg
snapshot.R
renv.lock
renv/
.Rprofile
README.qmd
README.md
29 changes: 14 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,30 @@
# Quarto-Clean-Typst Format

A minimalistic presentation theme for Quarto + Typst + [Touying](https://touying-typ.github.io).
Theme design is deeply inspired by Grant McDermott's [Clean theme](https://github.com/grantmcdermott/quarto-revealjs-clean) for Quarto + Reveal.js.

# Quarto-Clean-Typst Format

Click the image below to see a long [demo](https://kazuyanagimoto.com/quarto-slides-typst/slides/quarto-clean-typst/clean.pdf).
Code is available [here](https://github.com/kazuyanagimoto/quarto-slides-typst/blob/main/slides/quarto-clean-typst/clean.qmd).
A minimalistic presentation theme for Quarto + Typst +
[Touying](https://touying-typ.github.io). Theme design is deeply
inspired by Grant McDermott’s [Clean
theme](https://github.com/grantmcdermott/quarto-revealjs-clean) for
Quarto + Reveal.js.

[![Demo](thumbnail.png)](https://kazuyanagimoto.com/quarto-slides-typst/slides/quarto-clean-typst/clean.pdf)
Click the image below to see a long
[demo](https://kazuyanagimoto.com/quarto-clean-typst/template-full.pdf).
Code is available
[here](https://github.com/kazuyanagimoto/quarto-clean-typst/blob/main/template-full.qmd).

## Install
[![Demo](static/img/thumbnail.png)](https://kazuyanagimoto.com/quarto-slides-typst/slides/quarto-clean-typst/clean.pdf)

## Install

If you would like to add the clean theme to an existing directory:

```bash
``` bash
quarto install extension kazuyanagimoto/quarto-clean-typst
```

or you can use a Quarto template that bundles a .qmd starter file:


```bash
``` bash
quarto use template kazuyanagimoto/quarto-clean-typst
```





42 changes: 42 additions & 0 deletions README.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
format: gfm
---

# Quarto-Clean-Typst Format

A minimalistic presentation theme for Quarto + Typst + [Touying](https://touying-typ.github.io).
Theme design is deeply inspired by Grant McDermott's [Clean theme](https://github.com/grantmcdermott/quarto-revealjs-clean) for Quarto + Reveal.js.


Click the image below to see a long [demo](https://kazuyanagimoto.com/quarto-clean-typst/template-full.pdf).
Code is available [here](https://github.com/kazuyanagimoto/quarto-clean-typst/blob/main/template-full.qmd).

```{r}
#| include: false
system2("pdf2svg", args = c("docs/template-full.pdf", "static/img/thumbnail.svg"))
system2("pdftocairo", args = c("-png", "-f", "1", "-l", "1", "docs/template-full.pdf", "static/img/thumbnail"))
system2("mv", args = c("static/img/thumbnail-01.png", "static/img/thumbnail.png"))
```

[![Demo](static/img/thumbnail.png)](https://kazuyanagimoto.com/quarto-slides-typst/slides/quarto-clean-typst/clean.pdf)

## Install


If you would like to add the clean theme to an existing directory:

```bash
quarto install extension kazuyanagimoto/quarto-clean-typst
```

or you can use a Quarto template that bundles a .qmd starter file:


```bash
quarto use template kazuyanagimoto/quarto-clean-typst
```





6 changes: 6 additions & 0 deletions _quarto.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
project:
type: website
output-dir: docs
render:
- "*.qmd"
- "!static/"
7 changes: 7 additions & 0 deletions custom.typ
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#let _small-cite(self: none, it) = text(
size: 0.7em,
fill: self.colors.neutral-darkest.lighten(30%),
it
)

#let small-cite(it) = touying-fn-wrapper(_small-cite.with(it))
Loading

0 comments on commit dbb06eb

Please sign in to comment.