You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I got this situation in a tutorial: I'm giving people a really long docker-compose.yml listing, and asking them to run it.
I can tell them to copy it into a file, but that's no fun.
I can commit it as a separate file to the KC repo, but that's no fun, because if someone modifies the docs, we now have 2 sources of truth for the docker-compose file that need to stay in sync.
Any content in the source documentation needs to be ignored by Hugo to prevent it being rendered on the website. At the moment, the only mechanism is putting everything in HTML comments but that means every line of of the included content needs to be within a comment: https://github.com/grafana/killercoda/blob/staging/docs/transformer.md?plain=1#L213-L227.
Perhaps a Hugo shortcode that ignores its contents would make that more ergonomic:
```markdown
Information common to both pages.
{{< docs/ignore >}}
Information unique to the Killercoda page.
{{< /docs/ignore >}}
```
Produces:
Information common to both pages.
Information unique to the Killercoda page.
So I got this situation in a tutorial: I'm giving people a really long docker-compose.yml listing, and asking them to run it.
I can tell them to copy it into a file, but that's no fun.
I can commit it as a separate file to the KC repo, but that's no fun, because if someone modifies the docs, we now have 2 sources of truth for the docker-compose file that need to stay in sync.
What I'd really like to say is:
You can guess what that would do.
The text was updated successfully, but these errors were encountered: