[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] Question: org-remember and level>1 target headline

From: Martin Pohlack
Subject: Re: [Orgmode] Question: org-remember and level>1 target headline
Date: Thu, 13 May 2010 17:48:22 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20100410 Thunderbird/3.0.4


interest in this problem was indicated to me in private mail, so let my
sum up my findings so far.

I walked through the code in org-remember.el:org-remember-handler.

There seems to be no support for path traversal for the non-interactive
case.  The first headline matching is found regardless of its depth.

I now use the following structure for my plan files:

* Inbox
*** Inbox:host1
*** Inbox:host2
*** Inbox:host3

I use these two functions for computing the current target headline:

(defun my-host-name ()
  "Returns the name of the current host minus the domain."
  (let ((hostname (downcase (system-name))))
      (substring hostname (string-match "^[^.]+" hostname)
                          (match-end 0)))))

(defun my-org-remember-headline ()
  (concatenate 'string "Inbox:" (my-host-name)))

In one of the interactive paths in org-remember-handler, org-refile
infrastructure is used for inquiring a target from the user.  When
refiling, "/" in headline names are replaced with "\".  Verbatim "\" in
headlines are also presented as "\".  That means that "test/test" and
"test\test" cannot be distinguished for refiling.

Is there a specification of what are valid characters in a headline?

Is there interest to define remember targets via paths or via ID?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]