Skip to content

Commit a3b9e3b

Browse files
committed
Add a note about setting GH_TOKEN for TinyTeX API request
1 parent 13a0dde commit a3b9e3b

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

examples/quarto-publish-example.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ jobs:
2020

2121
- name: Set up Quarto
2222
uses: quarto-dev/quarto-actions/setup@v2
23+
env:
24+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2325
with:
2426
# To install LaTeX to build PDF book
2527
tinytex: true

setup/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,14 @@ We recommend using a Linux or MacOS runner if possible, especially if TinyTeX is
3535
```yaml
3636
steps:
3737
- uses: quarto-dev/quarto-actions/setup@v2
38+
env:
39+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3840
with:
3941
tinytex: true
4042
```
4143

44+
Setting `GH_TOKEN` is recommended as installing TinyTeX will query the github API. Otherwise, some API rate limit issue could happen which will make the step fails. A re-run of failed job on Github would solve it too.
45+
4246
### GitHub Enterprise
4347

4448
For GitHub Enterprise Server (GHES), you may need to [generate a personal access token (PAT) on github.com](https://github.com/settings/tokens/new) to enable downloading Quarto. GitHub's [setup-python action](https://github.com/actions/setup-python/blob/main/docs/advanced-usage.md#avoiding-rate-limit-issues) uses a similar workaround, from which these instructions are adapted:

0 commit comments

Comments
 (0)