From: Mirko Vukovic <mirko.vukovic@gmail.com>
To: emacs-orgmode@gnu.org
Subject: How to occasionally store link as file.org+headline
Date: Fri, 14 Feb 2020 11:48:35 -0500 [thread overview]
Message-ID: <CAO73BAARdUoW8LYGJvoWgzRvGAP7VYN+=RjAAWT2MZSNNU9DZQ@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 683 bytes --]
Hello,
For most of my links, I want to use the ID generated by orgmode
i.e., (setq org-id-link-to-org-use-id t)
But occasionally, for targets that are not part of my agenda files, I want
to store a link of the type file:path.org::*headline
I wrote the following function to accomplish that:
(defun org-store-file+headline ()
"Store link as file + headline"
(interactive)
(let ((org-id-link-to-org-use-id nil))
(org-store-link nil t)))
This function works (lightly tested).
But is there a built-in way, such as using prefixes or arguments to
org-store-link? I browsed the code for it, but that function is several
hundred lines long, and I gave up.
Thank you,
Mirko
[-- Attachment #2: Type: text/html, Size: 1077 bytes --]
next reply other threads:[~2020-02-14 16:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-14 16:48 Mirko Vukovic [this message]
2020-02-19 0:28 ` How to occasionally store link as file.org+headline Matthew Lundin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAO73BAARdUoW8LYGJvoWgzRvGAP7VYN+=RjAAWT2MZSNNU9DZQ@mail.gmail.com' \
--to=mirko.vukovic@gmail.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.