Jack Kamm <jackk...@gmail.com> writes: > In fact, :results file also works this way for other Babel languages. > And I used this behavior before for plotting with ob-reticulate blocks. > > I attach a patch to fix the documentation in the manual about this.
Your patch appear to only add more confusion, IMHO. I feel that the description about :results file is confusing from the very beginning: ‘file’ Interpret as a filename. Save the results of execution of the code block to that file, then insert a link to it. You can control both the filename and the description associated to the link. :results file may currently imply three things: 1. Results of evaluation are the _contents_ of a file 2. Results of evaluation are the path to a file 3. Results of evaluation are discarded and Org just inserts a constant link, derived from header arguments. (3) is used for :results file graphics/:results file link (2) is used when Org is unable to deduce the file name from :file/:file-ext+#+name (1) is used when the file name can be deduced from src block params > As an aside: I would like ":results graphics" to partially revert its > old behavior before Org 9.3. Prior to then, ob-R could generate a plot > with > > :results graphics :file filename.png > > but since commit 26ed66b23, we require the more verbose > > :results graphics file :file filename.png > > which seems unnecessarily verbose (since ":results graphics" doesn't do > anything without ":results file"), and also annoyingly broke many of my > Org documents before 2020. I think it would be better if ":results > graphics" was equivalent to ":results graphics file", and may propose a > patch for this in future. Sounds reasonable. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at <https://orgmode.org/>. Support Org development at <https://liberapay.com/org-mode>, or support my work at <https://liberapay.com/yantar92>