toshism / org-super-links

Package to create links with auto backlinks
GNU General Public License v3.0
285 stars 20 forks source link

A question about org-super-links-backlink-prefix customization #80

Open vincent-picaud opened 1 year ago

vincent-picaud commented 1 year ago

I have two files

file_A.org
* Introduction
file_B.org
* Introduction

what I would like when I create links is

* Introduction
:PROPERTIES:
:ID:       045bb041-3130-4ef8-bf50-f9ad0b284180
:END:
A link: [[id:a54fca82-c47a-4529-aa51-bb14403801a0][Introduction]]

Thank you for this package ! :)

toshism commented 1 year ago

Hey, interesting, you are right on the reason why it functions that way. I'll try to take a look at the code soon and see if there is a good way to handle that use case. It's been a bit since I've looked closely at it.

toshism commented 1 year ago

So unfortunately it looks like there is not really a straightforward way to do what you want. You could duplicate the org-super-links--insert-link and org-super-links-insert-backlink functions. Change org-super-links--insert-link to pass in the marker to the source as an extra param in the call to org-super-links-insert-backlink and then jump to the marker there to get the buffer name. You could do something similar by modifying org-super-links-links-action. Both feel pretty gross though.

If I think of something better I'll let you know.

vincent-picaud commented 1 year ago

Thank you for spending time to think about my problem.

I understand, and this is a valuable feedback.

Do you want me to close this question or to keep it active ?