All talks: https://emacsconf.org/2024/talks/
Literate programming for the 21st Century
https://emacsconf.org/2024/talks/literate - Howard Abrams - Track: General
Watch/participate: https://emacsconf.org/2024/watch/gen/
Q&A room: https://media.emacsconf.org/2024/current/bbb-literate.html
IRC: https://chat.emacsconf.org/#/connect?join=emacsconf,emacsconf-gen or #emacsconf-gen on libera.chat network
Guidelines for conduct: https://emacsconf.org/conduct
See end of file for license (CC Attribution-ShareAlike 4.0 + GPLv3 or later)
----------------------------------------------------------------
Notes, discussions, links, feedback:
----------------------------------------------------------------
Questions and answers go here:
- Q: Apropos large literate programs: what's the largest code base you've ever tackled with the literate approach (esp. Emacs + Org-mode)?
- A: The largest is the one I mentioned in the talk ... about 8000 lines of "code" and another "10000" lines of prose. I think I came to 15,000 max (in code blocks only).
- Q: You touched on it briefly, but how do you handle things like "C-h f" helpful info not being tied back to the defuns in src block code when you "C-c C-c" them in the org buffers instead of re-tangling it to the files, and other such things? Did you create wrappers for jumping back and forth atop org's built-in mechanisms to go back and forth between org/tangled files?
- Q: Have you ever used org-transclusion (https://github.com/nobiot/org-transclusion)?
- Q: What is your usage of dynamic blocks in such workflows? Any interesting use cases and custom ones?
- A: Not yet, will report back
- Q:Is the minibuffer being deliberately hidden in this video? (first noticed this in the section previous to "Navigating by Function Names")
- A: Not intentionally :) You may notice the minibuffer comes and goes, sorry about that; not intentional (didn't quite "fix" all of them) (Thanks for the answer, no worries.)
- Q:What's your take on Emacs+Org vs. Jupyter notebooks (for interactive programming)?
- A: Not something I use right now. Tend to include things from jupyter/python (e.g. numpy) that has been the biggest challenge (not knowing that stuff all that well), things like matrix multiplications are easy in jupyter not such much in org. May make sense to stay where you are comfortable. Curious what the community can do to make this transition easier
- You can't work with Jupyter in > 1 language either (I think). It's Py + SQL or R + SQL etc. Org allows 45+ languages in one document (I often mix languages).
- Q: Do you think any programming language is more suited to literate programming than another?
- A: R, C are my favorites (for literate programs). C (and C++) have got great support. There are some great books implemented in literate programming I think. The two that come to mind are Physically Based Rendering: From Theory to Implementation and C Interfaces and Implementations. The first is C++ and the second C. Ty.
- A: <gs-101> Personally, when working with Org files, I have a better time dealing with interpreted languages, such as Python, because you can initialize a session and the code is all conected. You can divide blocks however you seem fit.
- Q: related to above, do you use inline org function calls and org babel library and such?
- A: usta-use more org-babel inline functions, found sound bugs (maybe) 8yrs ago, right now my literate dev-ops is calling a lot of backend programs so the org-babel has limited help in that regard while in the emacs session things are "just available" so that hasn't help much either
- Q: How do you handle the cases where org markup may sometimes interfere with some of the code, in places where you can't use "escapes" (~ or = or | <- vertical bar), doubly so if you use modes to not show these but the styled text instead, and so on?
- I think an example is in C when you assign to a pointer *p = &i; (In Org, you need to write (*p) or ,*p = &i; or it will be mistaken for a headline *
- A: (clarifying) when I'm making pros and I'm talking about a function I've written somewhere else I'll use tildes and look for those things so I can strip them off. Is that the spirit of the question. (confirmed). Yes, I'll strip that off after finding the function name, so I can still mark it correctly.
- Q: clarifying: when in code inside an org buffer, you don't get to use ~ or = (verbatim/etc), and any font-locking interferes with the proper display in the src blocks, that kind of interference.
- Q: You said at the start that literate didn't catch on in corporate DevOps - why not?
- A: I guess the big thing is not everyone is using Emacs and org is needed to make it work really well.
- Q: I gotta ask: why not that full stack on Markdown, I'm sure it's crossed your mind at least a few times how the same setup on Markdown would be more interop-friendly with colleagues and such?
- A: It's a real good idea.
- Q: How does your management of "TODOs" (projects/tasks) interact with this literate mindset, any insightful things you do on that front?
- Q: <Donovan> Do you LP also on larger projects? (More files & nested directories)
- A: I haven't done nested directories, but I can now. Now that i've realized I have the feature where I can just jump to any projects and all the org-files and all the headings just show up, that works in nested directories, that that's fun.
- Q: Have you used Cucumber/Gherkin/BDD and do you think it has a strong overlap to what you talked about here?
- A: I tend to put the tests right next to the function, I like tangle it out to different files; keeping things together is nice. Many frameworks assume we'll have things seperated out in a way that isn't useful to me. I like to go old-school on that?
- Q: What granularity are you looking for re your org files and contents, with respect to a codebase that it tangles to, or in non-coding contexts?
- A: Great questions, really subjective. I change that all time. I have an idea, I start to refine it. My goal at one point was to have an emacs config that was really small and simple and that just really doesn't happen, it's full of ideas and things that are half-baked and i pull them out and polish them up bit by bit so it ends up being like any code-base it just keeps getting refined. Sub-trees, archiving are useful.
- I've found it useful to prune the init file back to minimal every once in a while (actually, AI has been surprisingly helpful - perhaps it helps that Emacs is ancient and hence there is a lot of doc out there and much of it ... correct?)
- Q: Not a Q, just a comment that we need more of your insightful posts and videos! :) (sic)
- Q:
- Q:
----------------------------------------------------------------
Next talks:
Questions/comments related to EmacsConf 2024 as a whole? https://pad.emacsconf.org/2024
----------------------------------------------------------------
This pad will be archived at https://emacsconf.org/2024/talks/literate after the conference.
Except where otherwise noted, the material on the EmacsConf pad are dual-licensed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International Public License; and the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) an later version. Copies of these two licenses are included in the EmacsConf wiki repository, in the COPYING.GPL and COPYING.CC-BY-SA files (https://emacsconf.org/COPYING/)
By contributing to this pad, you agree to make your contributions available under the above licenses. You are also promising that you are the author of your changes, or that you copied them from a work in the public domain or a work released under a free license that is compatible with the above two licenses. DO NOT SUBMIT COPYRIGHTED WORK WITHOUT PERMISSI