Nicolas Goaziou writes: >> ;; I tried to add this, but failed. because `coderef` is executed in `org-edit-src-code` which invokes `org-src--edit-element`, it create a dedicated buffer which does not have `buffer-file-name`. I don't know how to archive what I want now. >> ;; ((eq org-link-file-path-type 'adaptive) > > In "org-src.el", we create local variables to store information from > original buffer. See, e.g., `org-src--src-type' or `org-src--tab-width'. > Anyway, see my first question. Thanks for this hint, I added a new entry in org-src--babel-info list to pass the original parent file path.