patch added
This commit is contained in:
parent
b72b048c1e
commit
144bf1a4c6
14
README.md
14
README.md
|
@ -6,14 +6,16 @@ It works with HTML and LaTeX/PDF output.
|
|||
|
||||
*It works only with a patched version of quarto.*
|
||||
|
||||
Quarto itself supports ANSI colored/styled output only for HTML output and only for output cells of type `execute_result` ( and not for cells of type `stream output`). In all other cases it removes the ANSI escape sequences.
|
||||
At the moment, Quarto itself supports ANSI colored/styled output only for HTML output and only for output cells of type `execute_result` ( and not for cells of type `stream output`). In all other cases it removes the ANSI escape sequences.
|
||||
|
||||
This extension uses a hack employing the `ipynb-filters` option and only works if https://github.com/quarto-dev/quarto-cli/commit/6a4696af6ba5a8a9e3f78e3205b17c86eeecd0f9 is reverted.
|
||||
This extension uses a hack employing the `ipynb-filters` option and only works if https://github.com/quarto-dev/quarto-cli/commit/6a4696af6ba5a8a9e3f78e3205b17c86eeecd0f9 is reverted:
|
||||
|
||||
|
||||
```shell
|
||||
cd quarto-cli
|
||||
patch -p1 < patch-quarto
|
||||
```
|
||||
|
||||
#### Notes
|
||||
|
||||
- quarto per default calls pandoc with pandoc's `ipynb-output=best` option. Then pandoc removes ANSI escapes, see https://github.com/jgm/pandoc/commit/5454aad32474472a8f977c941e6f7d70e925bcc5
|
||||
- so we overwrite this option and the lua filter as to reproduce the behaviour of this option, i.e., select the best output cell variant
|
||||
- The current quarto behaviour is https://github.com/quarto-dev/quarto-cli/issues/929
|
||||
All code licenced under [GNU General Public License v2.0 or later](https://spdx.org/licenses/GPL-2.0-or-later.html)
|
||||
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
diff --git a/src/execute/jupyter/jupyter.ts b/src/execute/jupyter/jupyter.ts
|
||||
index 750eff367..3028c10ed 100644
|
||||
--- a/src/execute/jupyter/jupyter.ts
|
||||
+++ b/src/execute/jupyter/jupyter.ts
|
||||
@@ -286,9 +286,7 @@ export const jupyterEngine: ExecutionEngine = {
|
||||
// if the source is an ipynb file)
|
||||
const nbContents = await jupyterNotebookFiltered(
|
||||
options.target.input,
|
||||
- isJupyterNotebook(options.target.source)
|
||||
- ? options.format.execute[kIpynbFilters]
|
||||
- : [],
|
||||
+ options.format.execute[kIpynbFilters],
|
||||
);
|
||||
const nb = jupyterFromJSON(nbContents);
|
||||
const assets = jupyterAssets(
|
Loading…
Reference in New Issue