Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate single format example in its own file #42

Merged
merged 1 commit into from
Aug 25, 2022
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
19 changes: 0 additions & 19 deletions examples/example-04-other-workflows.md

This file was deleted.

8 changes: 8 additions & 0 deletions examples/example-04-render-no-publish.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Quarto Actions: Render without publishing

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:

```yaml
- name: Render Quarto Project
uses: quarto-dev/quarto-actions/render@v2
```
2 changes: 1 addition & 1 deletion examples/example-05-non-top-level.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Using Quarto Actions: non-top-level projects
# Quarto Actions: non-top-level projects

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:

Expand Down
22 changes: 1 addition & 21 deletions examples/example-06-no-render.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Publishing without rendering
# Quarto Actions: Publishing without rendering

By default, the `quarto-actions/publish@v2` action will re-render your entire project before publishing.
However, if you store the rendered project in version control, you don't need
Expand All @@ -12,23 +12,3 @@ to the `publish` action:
target: gh-pages
render: false
```

## Rendering a single format

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:

* use the `quarto-actions/render@v2` action and provide a target output format (in this example YAML configuration, we use the HTML format)
* 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)

```yaml
- name: Render Book project
uses: quarto-dev/quarto-actions/render@v2
with:
to: html

- name: Publish HTML book
uses: quarto-dev/quarto-actions/publish@v2
with:
target: gh-pages
render: false
```
19 changes: 19 additions & 0 deletions examples/example-07-publish-single-format.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Quarto Actions: Rendering a single format

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:

* use the `quarto-actions/render@v2` action and provide a target output format (in this example YAML configuration, we use the HTML format)
* 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)

```yaml
- name: Render Book project
uses: quarto-dev/quarto-actions/render@v2
with:
to: html

- name: Publish HTML book
uses: quarto-dev/quarto-actions/publish@v2
with:
target: gh-pages
render: false
```