Re: [O] How to generate a list of ``who-links''?

2018-10-14 Thread Samuel Wales
this is good eonugh for me but perhaps you want to improve on it.

(define-key org-mode-map (kbd "C-c w") 'alpha-org-what-links-here)
(defun alpha-org-what-links-here ()
  "Show all links that point to the current node.
Possibly also show the target node itself.

  - fixme Bug in Org: g in agenda removes entries
  - fixme org text search does not work in non-org-mode files or
in org files text above the outline tree ka

This makes id links quasi-bidirectional.
"
  (interactive)
  (let ((org-agenda-files (alpha-org-all-org-files))

org-agenda-skip-comment-trees
org-agenda-skip-archived-trees

(search-string (or
;; raw id so it will pick up target
(alpha-awhen (org-entry-get nil "ID" t)
  (regexp-quote it))
(concat "{\\("
;; tries searching a link to id
;; not sure if useful
(regexp-quote (org-store-link nil))
"\\|\\<"
;; not sure if useful
(regexp-quote (org-get-heading))
"\\>\\)}"
(org-search-view nil search-string)))

On 10/14/18, Mirko Vukovic  wrote:
> Hello,
>
> I am looking for a way to get a list of all remote references to the
> current node?
>
> Currently, I do:
> - org-id-copy
> - In org-agenda I search the copied id.
>
> Is there
> - a better built-in way?
> - a contributed-package?
> - a suggestion how to code it in my elisp?
>
> Thanks,
>
> Mirko
>


-- 
The Kafka Pandemic: 

The disease DOES progress. MANY people have died from it. And ANYBODY
can get it at any time.

"You’ve really gotta quit this and get moving, because this is murder
by neglect." ---
.



[O] How to generate a list of ``who-links''?

2018-10-14 Thread Mirko Vukovic
Hello,

I am looking for a way to get a list of all remote references to the
current node?

Currently, I do:
- org-id-copy
- In org-agenda I search the copied id.

Is there
- a better built-in way?
- a contributed-package?
- a suggestion how to code it in my elisp?

Thanks,

Mirko