Skip to content

Commit ad65f69

Browse files
authored
Separate single format example in its own file (#42)
for easier discovery as it was already hidden in two places. Related to #41
1 parent 5391a72 commit ad65f69

File tree

5 files changed

+29
-41
lines changed

5 files changed

+29
-41
lines changed

examples/example-04-other-workflows.md

Lines changed: 0 additions & 19 deletions
This file was deleted.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Quarto Actions: Render without publishing
2+
3+
If you need to render your project in a GitHub Action, but will use the output for something besides publishing (or publishing to a service not supported by `quarto publish`), then instead of `publish`, use the `render` action:
4+
5+
```yaml
6+
- name: Render Quarto Project
7+
uses: quarto-dev/quarto-actions/render@v2
8+
```

examples/example-05-non-top-level.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Using Quarto Actions: non-top-level projects
1+
# Quarto Actions: non-top-level projects
22

33
It's possible to have a quarto project in a large GitHub repository, where the quarto project does not reside at the top-level directory. In this case, add a `path` input to the invocation of the `render` or `publish` action. For example:
44

examples/example-06-no-render.md

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Publishing without rendering
1+
# Quarto Actions: Publishing without rendering
22

33
By default, the `quarto-actions/publish@v2` action will re-render your entire project before publishing.
44
However, if you store the rendered project in version control, you don't need
@@ -12,23 +12,3 @@ to the `publish` action:
1212
target: gh-pages
1313
render: false
1414
```
15-
16-
## Rendering a single format
17-
18-
The `render: false` choice is all-or-nothing. If you need to customize the rendering step, e.g. only render one format in CI before publishing, use a two step process:
19-
20-
* use the `quarto-actions/render@v2` action and provide a target output format (in this example YAML configuration, we use the HTML format)
21-
* use the `quarto-actions/publish@v2` action with `render: false` to skip rendering before publishing (in this example YAML configuration, we publish to GitHub Pages)
22-
23-
```yaml
24-
- name: Render Book project
25-
uses: quarto-dev/quarto-actions/render@v2
26-
with:
27-
to: html
28-
29-
- name: Publish HTML book
30-
uses: quarto-dev/quarto-actions/publish@v2
31-
with:
32-
target: gh-pages
33-
render: false
34-
```
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Quarto Actions: Rendering a single format
2+
3+
With the `publish` action, it is either rendering all format by default, or none with `render: false`. If you need to customize the rendering step, e.g. only render one format in CI before publishing, use a two step process:
4+
5+
* use the `quarto-actions/render@v2` action and provide a target output format (in this example YAML configuration, we use the HTML format)
6+
* use the `quarto-actions/publish@v2` action with `render: false` to skip rendering before publishing (in this example YAML configuration, we publish to GitHub Pages)
7+
8+
```yaml
9+
- name: Render Book project
10+
uses: quarto-dev/quarto-actions/render@v2
11+
with:
12+
to: html
13+
14+
- name: Publish HTML book
15+
uses: quarto-dev/quarto-actions/publish@v2
16+
with:
17+
target: gh-pages
18+
render: false
19+
```

0 commit comments

Comments
 (0)