Tangentially, has there been any work in having more structured scrollback, say one buffer for every command, which can be collapsed, pinned or copied individually? Presently there's the minor annoyance when (accidentally) running any program with lots of output, which is that all the scrollback above it becomes inaccessible. Yeah, could have run them in different splits or redirected to begin with, but sometimes you…
EShell in Emacs can preserve point at the prompt that executed the command. You can then hit space to page through the output, or start typing to immediately jump to the end of the buffer (and thus a blank prompt): https://www.masteringemacs.org/article/complete-guide-master... There's also `C-c C-p` to jump to the previous command prompt in the likes of M-x shell. That's not quite what you want, but it's another way…
Run programs in Emacs buffer, seeing their output inline, interactively
11–20 of 39 posts
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#12This is useful! Are there other packages on MELPA that provide similar functionality?
`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…
Also did a little experiment for Objective-C https://xenodium.com/org-babel-objective-c-support
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#13Re: Run programs in Emacs buffer, seeing their output inline, interactively
#14OTOH, org-mode already does this, without any need for external package and minimal config. It works really well, too!
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#15I am loving the latest Emacs Renaissance! All you can eat buffet, but you can take your lunch (and dinner) home :) OTOH, org-mode already does this, without any need for external package and minimal config. It works really well, too!
*rimshot*
Thank you, I am here all week.
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#16Tangentially, has there been any work in having more structured scrollback, say one buffer for every command, which can be collapsed, pinned or copied individually? Presently there's the minor annoyance when (accidentally) running any program with lots of output, which is that all the scrollback above it becomes inaccessible. Yeah, could have run them in different splits or redirected to begin with, but sometimes you…
it was very ambitious but I don't know where it's at now
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#17I am loving the latest Emacs Renaissance! All you can eat buffet, but you can take your lunch (and dinner) home :) OTOH, org-mode already does this, without any need for external package and minimal config. It works really well, too!
> one keystroke executes all specially-marked lines from a buffer and inserts the results inline
Not sure if we can make such specially-marked lines using org-mode. Never needed this feature myself. But for those who want a workflow like this the new package could be useful. But again maybe there is a way to do this without an external package with a little bit of elisp?
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#18Earlier quoted context omitted.
`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…
Extending 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-rev... Also did a little experiment for Objective-C https://xenodium.com/org-babel-objective-c-support
Re: Run programs in Emacs buffer, seeing their output inline, interactively
#19This is useful! Are there other packages on MELPA that provide similar functionality?