2

I'm setting up something similar to org-depend, but more plain-text.

I have a sub item with an id:

* TODO my sub task
  :PROPERTIES:
  :ID:       b988fcc3-5f73-4f4c-8b90-38c63d3ee72c
  :END:
  task notes

And another task that points to it via a link with id:

* TODO master task
 - [ ] bake cake 
 - [ ] [[id:b988fcc3-5f73-4f4c-8b90-38c63d3ee72c][my sub task]]

Now for the sub task, in the title like I want to insert an elisp link that jumps to what ever links to it. Like so:

* TODO my sub task [[elisp:(org-occur-link-in-agenda-files)][parent]]

Now when I run org-occur-link-in-agenda-files in M - x , I get a list of links. But the above command inside an elisp link in the title doesn't do anything, it just prints 't' in the output line.

Does anyone know how to implement this?

[edit]
This works only if the parent is below the child and only in the same file.

[[elisp:(search-forward-regexp (concat "id:" (org-id-get-create)))]]

Now it would be good to be able to go to the first matching regex item somehow?

0

I managed to solve this in: global-goto-regex
With the code available therein, I can add this to the child task: [[elisp:(my/goto-parent)][parent]] and it jumps to what ever has linked to it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.