Jupyter notebook to emacs' org-mode format
See original GitHub issueEmacs’ org mode format (extension .org
) has a well documented syntax for code blocks:
#+NAME: <name>
#+BEGIN_SRC <language> <switches> <header arguments>
<body>
#+END_SRC
We could implement a notebook to/from org converter.
Further notes:
- The
NAME
option seems optional. - Examples are available here
- Org mode has a header with metadata. Can it hold the Jupyter notebook metadata?
- Also, it’s not clear how cell metadata could be represented in org mode
Issue Analytics
- State:
- Created 5 years ago
- Reactions:16
- Comments:13 (7 by maintainers)
Top Results From Across the Web
Org-mode as a lightweight Jupyter notebook
An org file is a plain text file, and you can execute embedded code right there in your editor. You don't need a...
Read more >Replacing Jupyter Notebook with Org Mode - SqrtMinusOne
Yet another solution is to use emacs-jupyter's option :pandoc t , which invokes pandoc to convert HTML, LaTeX, and Markdown to Org. Predictably, ......
Read more >Convert Jupyter notebook to Emacs Org mode for ... - Alldocs
Looking for a free text converter? Look no more, upload your Jupyter notebook files and convert them to Emacs Org mode files. Yes,...
Read more >Integrating jupyter notebook (ipython) into org-mode notebook
Run code on remote ipython kernels with Emacs and orgmode provides a basic example using exactly that library, and there are more related ......
Read more >Comparing org-mode in Emacs vs Notebooks in Jupyter - Reddit
I have a feeling that Jupyter notebooks in nowadays remind me org-mode in Emacs. Both can be used: for text notes;
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@srnnkls , if that can help, I have prepared a branch with a tentative implementation of the
org
format based onpandoc
(back and forth), see the last three commits here: https://github.com/mwouts/jupytext/commits/org_pandoc:org:pandoc
format to Jupytext (and simply callspandoc
)Note that the round trip test does not work. Is it correct that pandoc’s conversion only works in one direction (ipynb to org)? Any way, feel free to experiment with this, and replace either converter with your favorite one.
Two additional comments:
pandoc
(because they are preserved in the.ipynb
file), so no headache with outputs…pandoc
is used for themd:pandoc
format, but that is not Jupytext’s default markdown format (see the example files at https://github.com/mwouts/jupytext/tree/master/demo )Just a note for the people who subscribed to this thread… I have opened an issue at pandoc regarding the round trip ipynb-org-ipynb: https://github.com/jgm/pandoc/issues/6367.
The issue also raises the question of how the notebook cells should be represented in org mode. Personally I think that the representation should remain as simple as possible, because the users are going to type it 😃 But obviously, it is simpler for the programmers (and maybe also safer in the long run?) to use explicit cell markers. Anyway… if you have an opinion about this, please follow the pandoc thread as well!