emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Colons in :var header arguments


From: Stefano Ghirlanda
Subject: Colons in :var header arguments
Date: Thu, 19 Oct 2023 06:34:11 -0700

Hi everyone,

I have been using org-mode for reproducible research for many years
now. This is my first message: thanks to everyone who is involved in
org-mode development and maintenance!

I have run into an inconvenience in that colons in :var header
arguments to source blocks are invariably interpreted as referring to
another file. However, I use cleveref in LaTeX export (via org-ref) to
automatically format references using labels like tab:data, and in
these cases :var data=tab:data gives a reference not found because tab
is interpreted as a filename.

I have found a workaround in that I can use #+name: data to name the
table as well as \label{tab:data} in the table's #+caption: line, and
this works. But I was wondering if it would be cleaner to change this
behavior to interpreting tab:data as referring to a file only if
#+name: tab:data is not found in the current file. I think this would
break very few org files currently in the world, because presumably
people using the external file mechanism have not been using the
cleveref mechanism, otherwise this would have popped up already :) In
org files that use external references only, the change would be
invisible. I see the magic happens in org-ref-resolve in org-ref.el,
but I don't feel confident enough to mess with that myself.

Thanks again for one of the most useful pieces of software around.

-- 
Stefano Ghirlanda
CTO, DataWorks - https://dataworks.consulting
Guest Professor - Stockholm University Centre for Cultural Evolution



reply via email to

[Prev in Thread] Current Thread [Next in Thread]