Hello,

stardiviner <numbch...@gmail.com> writes:

> Thanks for this hint, I added a new entry in org-src--babel-info list to
> pass the original parent file path.

Thank you. Some comments follow.

> -  (language body arguments switches name start coderef)"
> +  (language body arguments switches name start coderef  parent-file-path)"

This is not needed. It would be better to create a new variable, e.g.
`org-src-source-file', get the file name at the beginning of the
function `org-src--edit-element', and set it from its INITIALIZE
argument.

> +                (insert (format coderef-format label))
> +                (setq link (format "file:%s::%s"
> +                                   (car (last org-src--babel-info))
> +                                   (concat "(" label ")")))

You can get the file name by reading `org-src-source-file' value.

Does that make sense?

Could you also provide some tests?

Regards,

-- 
Nicolas Goaziou

Reply via email to