Thanks for the links, loads of rich content in there, e.g. the first code chunk in the last link is as follows:
quarto inspect index.qmd | jq '
.fileInformation[].codeCells |
map(
.metadata = (.metadata | to_entries | map("#| \(.key): \(.value)") | join("\n"))
) |
group_by(.language) |
map({
language: .[0].language,
contents: map(.metadata + "\n" + .source) | join("\n")
})
'
I wonder if the same job could be achieved with a shorter incantation at some point e.g.
quarto extract --language=Python index.qmd
Originally posted by @Robinlovelace in #389
Related to #208 which is about R code cell