https://github.com/wardbrian/quarto-show-code
A shortcode for including highlighted code from another file
https://github.com/wardbrian/quarto-show-code
Last synced: 9 months ago
JSON representation
A shortcode for including highlighted code from another file
- Host: GitHub
- URL: https://github.com/wardbrian/quarto-show-code
- Owner: WardBrian
- License: mit
- Created: 2022-08-18T14:23:44.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-08-18T14:30:42.000Z (almost 4 years ago)
- Last Synced: 2025-01-28T15:23:47.352Z (over 1 year ago)
- Language: Lua
- Size: 229 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Quarto-show-code
This is a [quarto](https://quarto.org/) extension
for displaying source code from a file in a document. This allows you to
have a single source of truth for code examples and avoid duplication.
```
quarto install extension WardBrian/quarto-show-code
```
```
{{ showcode path/to/my/file.c }}
```
This also supports the optional arguments `language` to override the highlighting and
`skiplines` to skip the first `n` lines from the file (useful for skipping a preamble)
See the [example](https://brianward.dev/quarto-show-code/)