-
Notifications
You must be signed in to change notification settings - Fork 13
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
Feature request: Force execution of all code cells without adding .cb-run
and .cb-nb
#59
Comments
Alternative implementation: Support a YAML keyword ---
codebraid:
jupyter:
kernel: python3
timeout: 120
runall:
- python
- bash
--- |
To get something working immediately, I'd suggest running Pandoc with a filter on the original file to add the Codebraid classes, and then piping the Pandoc output through Codebraid. Something like this should work for the filter:
And then run with a command like this:
I like the idea of adding a feature like this in the YAML. I'm planning to add YAML features for setting default code chunk options, and adding a feature like this would basically amount to the same thing except setting defaults for all code chunks, not just those marked with Codebraid classes. I'm currently working on updating some of my other open-source projects after focusing on Codebraid Preview earlier this year, so I may not be able to work on adding new features for a while. |
Thanks a lot! Yes, I will be using a filter for the time being! |
Hi,
it would be handy to have a command-line option that automatically adds either
.cb-run
or
.cb-run
and.cb-nb
or the respective behavior to all Python code block.
Motivation: I often create Python materials in Pandoc markdown and would want to produce a lecture note with the code snippets and their effects side-by-side. While I could manually add
{.python .cb-run .cb-nb}
to each code block, that seems like unnecessary redundancy. Before I start writing a custom Pandoc filter that adds.cb-run
and.cb-nb
to all code blocks in a Pandoc document, I wanted to check if there is another way with batteries supplied.Implementation: I would use a CLI option like
--runall
--runall python
--runall python,bash
The text was updated successfully, but these errors were encountered: