3 ms·
`org-mode` has the ability to evaluate code blocks and store the output in a following results block[0]. You can configure it to run just about everything in v
by merlincorey 4y ago
`org-mode` has the ability to evaluate code blocks and store the output in a following results block[0].
You can configure it to run just about everything in various ways and therefore you can do Literate Programming in nearly the full Knuth sense in it.
I find it's a good solution for a local "notebook" similar to IPython/Jupyter Notebooks but for any language in Emacs.
[0] https://orgmode.org/manual/Evaluating-Code-Blocks.html https://orgmode.org/manual/Evaluating-Code-Blocks.html
- aesyondu 4y agoOrg+babel is probably my favorite thing about emacs, magit being a close second. I tried doing Literate Programming using this blog as my guide http://fgiasson.com/blog/index.php/2016/06/21/optimal-emacs-settings-for-org-mode-for-literate-programming/ http://fgiasson.com/blog/index.php/2016/06/21/optimal-emacs-..., but I got burned out pretty quickly. I think my problem was I put literally everything in a single README.org file, and it was so taxing scrolling up and down. I might try again but with multiple org files.
- xenodium 4y agoExtending org babel to support other languages is fairly accessible. I had a lot of fun getting SwiftUI to rendering inline https://xenodium.com/previewing-swiftui-layouts-in-emacs-revisited https://xenodium.com/previewing-swiftui-layouts-in-emacs-rev... Also did a little experiment for Objective-C https://xenodium.com/org-babel-objective-c-support https://xenodium.com/org-babel-objective-c-support
- ghosty141 4y agoThe first link is really impressive. Amazing what can be achieved with so little code/configuration.