[ANN] public-inbox archive of the mailing list
I've set up a public-inbox [^1] archive of the mailing list at https://yhetil.org/orgmode/ It should be fairly complete, going back to the earliest non-test email listed in the lists.gnu.org archive [^2]. If you notice that a message is missing, please first check whether you can find it with a +message-id: search against the gnu.org archive. If you can't find it there, it probably didn't make it to the list; if you can, please let me know. New messages should hit the archive within 15 minutes or so. I should say more about why I think public-inbox is great [^3], but I doubt I could do it justice while keeping this email short. Anyway, if you'd like to have a look, perhaps start here: (eww "https://yhetil.org/orgmode/_/text/help/";) (eww "https://yhetil.org/orgmode/871uc8mtpy@poukram.net/";) [^1]: https://public-inbox.org/README [^2]: https://lists.gnu.org/archive/html/emacs-orgmode/ [^3]: I'm not alone :> https://public-inbox.org/meta/20190912135606.GE16671@pure.paranoia.local/ https://public-inbox.org/git/nycvar.qro.7.76.6.1808271552580...@tvgsbejvaqbjf.bet/
Re: Org-babel-lilypond always renders full pages
Hi On 02 Apr 2020, stardiviner wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA256 > > > Jonathan Gregory writes: > >> Hi >> >> On 30 Mar 2020, stardiviner wrote: >> >>> -BEGIN PGP SIGNED MESSAGE- >>> Hash: SHA256 >>> >>> >>> stardiviner writes: >>> -BEGIN PGP SIGNED MESSAGE- Hash: SHA256 You might want to try this: #+begin_src emacs-lisp (add-to-list 'org-babel-default-header-args:lilypond '((:prologue . "\paper{ indent=0\mm line-width=120\mm oddFooterMarkup=##f oddHeaderMarkup=##f bookTitleMarkup = ##f scoreTitleMarkup = ##f }"))) #+end_src >>> >>> I found this custom setting lilypond header arguments will not work. >>> Because this code function: >>> >>> #+begin_src emacs-lisp >>> (defun org-babel-lilypond-get-header-args (mode) >>> "Default arguments to use when evaluating a lilypond source block. >>> These depend upon whether we are in Arrange mode i.e. MODE is t." >>> (cond (mode >>> '((:tangle . "yes") >>>(:noweb . "yes") >>>(:results . "silent") >>>(:cache . "yes") >>>(:comments . "yes"))) >>> (t >>> '((:results . "file") >>>(:exports . "results") >>> >>> (defun org-babel-lilypond-set-header-args (mode) >>> "Set org-babel-default-header-args:lilypond >>> dependent on ORG-BABEL-LILYPOND-ARRANGE-MODE." >>> (setq org-babel-default-header-args:lilypond >>> (org-babel-lilypond-get-header-args mode))) >>> #+end_src >>> >>> It always reset and return one result of two conditions. >>> >>> I think this is a bug. >> >> So are all org-babel-default-header-args:LANG custom variables? In the >> ob-lilypond.el library the headers are hard-coded. >> >> [...] > > Yes, it's hard-coded in that function definition. So setting that header > arguments variable will not work at all. OK, I had a closer look and none of the other libraries set org-babel-default-header-args:LANG in the file itself. IOW ob-lilypond is the only one that does this, and it does this to allow toggling between two modes (basic and arrange) and setting the header args relative to the mode used. But there's a cost to resetting org-babel-default-header-args:lilypond which is it prevents users from making modifications to it. I'm not sure how to deal with this. Maybe others can chime in. -- Jonathan
Re: Improving Org Mode for VSCode - Thinking Aloud
I think this is a great idea. I actually looked at the two org-mode implementations on VS Code a long while back and was impressed they'd gotten as far as they had. Besides the basic support they already have, for me the big win for them would be able to take advantage of the emacs plugin ecosystem somehow (though I have no idea how you'd run some sort of in-VSC lisp interpreter to make some of the plugins work). I know, however, that the big org-mode boon for me is having packages like deft, org-super-agenda, org-journal etc as well and being able to have org-agenda/todos and org-contacts working in there. What did you have in mind, exactly? (cuz strangely I am using VS Code more and more for coding, and emacs more as a note, journaling, organization, and GTD app... 8-/ ) Daryl. On Fri, Apr 3, 2020 at 12:01 AM wrote: > Send Emacs-orgmode mailing list submissions to > emacs-orgmode@gnu.org > -- > > Message: 4 > Date: Wed, 1 Apr 2020 12:55:27 -0500 > From: George Mauer > To: emacs-orgmode > Subject: Improving Org Mode for VSCode - Thinking Aloud > Message-ID: > < > ca+pajwk0_jivdfwrhepxlu21vl+ivpayn8zarvudvvmppdj...@mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > With VSCode becoming ever-popular it seems like there might be some value > in getting org mode working there simply as a way of promoting org as an > excellent literate coding notebook. > > VSCode already has a halfway decent org-mode but it doesn’t support > anything from Babel. I’m trying to think of relatively easy ways of adding > that ability. Here’s a thought: Most of babel that technically works > against the document itself, it doesn’t really need much document > integration with the editor. So could you get it working in vscode so long > as someone has a properly configured version of emacs installed locally? > “Evaluate/Export/etc” would just write the document, then use emacs to run > the appropriate commands on it and refresh the document view. > > Of course features like the separate editor for src blocks and > folding #results would be nice too, but if the basics could work that would > be a huge win for org. > > Any thoughts on the feasibility of this? > -- next part -- > An HTML attachment was scrubbed... > URL: < > https://lists.gnu.org/archive/html/emacs-orgmode/attachments/20200401/2f8e3466/attachment.html > > > > -- > > >
Re: rmarkdown-like production of multiple plots in org
Thanks Chuck and all other respondents. Huh. I'll keep experimenting. I like Chuck's idea of helper function that pipes theoutput as described but for now, it might actually beeasier to stay with Rmarkdown (!). thanks, Matt On Thu, Apr 2, 2020 at 1:39 PM Berry, Charles wrote: > > > > On Mar 31, 2020, at 12:23 PM, Matt Price wrote: > > > > I'm completely new to R. > > > > I've started working with a project that creates plots using the ggplot > package -- so by default it creates grid objects, rather than writing to > files. > > > > In rmarkdown/rstudio, I can write something like this in a SOMEFILE.Rmd > : > > > > ``` > > install_github('eeholmes/CoV19') > > library(CoV19) > > getdata(); > > plot4(world, 'Ontario Canada') > > plot2(world, 'Italy') > > plot4(states, "WA") > > ``` > > > > I sort of love how the rmarkdown package will just create all 3 of those > plots, save them to auto-named files, and render to HTML. > > Actually, this is knitr (which rmarkdown Imports) at work. There are > options as to how knitr will handle multiple plots in a chunk as described > in > > https://yihui.org/knitr/options/#plots > > (which include `fig.show="animate"' to create an animation based on > multiple plots!) > > So this applies to various filetypes in addition to *.Rmd (*.Rnw, for > one). > > > > In RStudio, running just that block will also create all three blocks > and display them in the editor. > > > > By contrast, creating a series of many plots in org is fairly tedious. > I have to name the plot individually & put each function call in its own > src block. Is there any way to mimic the behaviour of rmarkdown instead? I > odn't understand babel or R enough to really even see how something like > that could be implemented, but I'd appreciate some pointers. Thank you! > > Getting babel to handle this seamlessly would be a significant effort. > > You can use ox-ravel (https://github.com/chasberry/orgmode-accessories.git) > to export to *.Rmd and then render the result. However, that does not have > the interactivity of `org-babel-execute-src-block' and does not insert the > graphics into the *.org file. > > I suppose that a function could be created to narrow to the src block, > export it as *.Rmd to a buffer, run that buffer as the `text' arg of > knitr::knit, then add links for the png's back to the *.org file. I haven't > thought much about this - getting this to work in a simple case would not > be too hard, but there may be a can of worms that this approach opens. > > HTH, > > Chuck > > >
Re: rmarkdown-like production of multiple plots in org
> On Mar 31, 2020, at 12:23 PM, Matt Price wrote: > > I'm completely new to R. > > I've started working with a project that creates plots using the ggplot > package -- so by default it creates grid objects, rather than writing to > files. > > In rmarkdown/rstudio, I can write something like this in a SOMEFILE.Rmd : > > ``` > install_github('eeholmes/CoV19') > library(CoV19) > getdata(); > plot4(world, 'Ontario Canada') > plot2(world, 'Italy') > plot4(states, "WA") > ``` > > I sort of love how the rmarkdown package will just create all 3 of those > plots, save them to auto-named files, and render to HTML. Actually, this is knitr (which rmarkdown Imports) at work. There are options as to how knitr will handle multiple plots in a chunk as described in https://yihui.org/knitr/options/#plots (which include `fig.show="animate"' to create an animation based on multiple plots!) So this applies to various filetypes in addition to *.Rmd (*.Rnw, for one). > In RStudio, running just that block will also create all three blocks and > display them in the editor. > > By contrast, creating a series of many plots in org is fairly tedious. I > have to name the plot individually & put each function call in its own src > block. Is there any way to mimic the behaviour of rmarkdown instead? I odn't > understand babel or R enough to really even see how something like that could > be implemented, but I'd appreciate some pointers. Thank you! Getting babel to handle this seamlessly would be a significant effort. You can use ox-ravel (https://github.com/chasberry/orgmode-accessories.git) to export to *.Rmd and then render the result. However, that does not have the interactivity of `org-babel-execute-src-block' and does not insert the graphics into the *.org file. I suppose that a function could be created to narrow to the src block, export it as *.Rmd to a buffer, run that buffer as the `text' arg of knitr::knit, then add links for the png's back to the *.org file. I haven't thought much about this - getting this to work in a simple case would not be too hard, but there may be a can of worms that this approach opens. HTH, Chuck
Re: Org-babel-lilypond always renders full pages
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Jonathan Gregory writes: > Hi > > On 30 Mar 2020, stardiviner wrote: > >> -BEGIN PGP SIGNED MESSAGE- >> Hash: SHA256 >> >> >> stardiviner writes: >> >>> -BEGIN PGP SIGNED MESSAGE- >>> Hash: SHA256 >>> >>> >>> You might want to try this: >>> >>> #+begin_src emacs-lisp >>> (add-to-list 'org-babel-default-header-args:lilypond >>> '((:prologue . "\paper{ >>> indent=0\mm >>> line-width=120\mm >>> oddFooterMarkup=##f >>> oddHeaderMarkup=##f >>> bookTitleMarkup = ##f >>> scoreTitleMarkup = ##f >>> }"))) >>> #+end_src >>> >> >> I found this custom setting lilypond header arguments will not work. Because >> this code function: >> >> #+begin_src emacs-lisp >> (defun org-babel-lilypond-get-header-args (mode) >> "Default arguments to use when evaluating a lilypond source block. >> These depend upon whether we are in Arrange mode i.e. MODE is t." >> (cond (mode >> '((:tangle . "yes") >>(:noweb . "yes") >>(:results . "silent") >>(:cache . "yes") >>(:comments . "yes"))) >> (t >> '((:results . "file") >>(:exports . "results") >> >> (defun org-babel-lilypond-set-header-args (mode) >> "Set org-babel-default-header-args:lilypond >> dependent on ORG-BABEL-LILYPOND-ARRANGE-MODE." >> (setq org-babel-default-header-args:lilypond >> (org-babel-lilypond-get-header-args mode))) >> #+end_src >> >> It always reset and return one result of two conditions. >> >> I think this is a bug. > > So are all org-babel-default-header-args:LANG custom variables? In the > ob-lilypond.el library the headers are hard-coded. > > [...] Yes, it's hard-coded in that function definition. So setting that header arguments variable will not work at all. - -- [ stardiviner ] I try to make every word tell the meaning what I want to express. Blog: https://stardiviner.github.io/ IRC(freenode): stardiviner, Matrix: stardiviner GPG: F09F650D7D674819892591401B5DF1C95AE89AC3 -BEGIN PGP SIGNATURE- iQFIBAEBCAAyFiEE8J9lDX1nSBmJJZFAG13xyVromsMFAl6Fo7oUHG51bWJjaGls ZEBnbWFpbC5jb20ACgkQG13xyVromsP2cQf7Bj8/dS+k/P5Hu5sF9gccS8mzrIWL aLrJ/lFtkkwP7IbAUTYxW3zNAISHSa285oCha2gWzqT8Vc2Vv/NIhpwVKOvq5Ifg L9FRQuftP3hHekdVAcSwPFMV0ejXPI3vItCzgDhk1+G3BcMwphW37LfOT5v0Sj0D 47cGBhgobPhX4Q3vtPonCdtSgt+bhEsi0Xxa+uNmfhOEEhVflEgvcSLcXtPs5cuv zkUZhJXCmPx/qFlMT0DphsGk/KLX/NXTfLFQvZ0lA30Vl2Hypnsa6L32MIlZZJOU rIRgYOwGsFxCCSZfRm6SosVhSApZmJCR9BbjPwVYOlnScJJr8uXsw9ofTA== =cyEM -END PGP SIGNATURE-