Hi all,

I'm trying to figure out how to get org-mobile-pull to work for me.  I
want to be able to edit files from multiple directories via MobileOrg,
e.g.:

  ~/org/TODO.org
  ~/work/TODO.org
  ~/my-project/TODO.org
  ~/org/notes/my-hobby.org

I have a sync-org shell-script which copies them into a temporary
directory, and then runs the following via emacs --batch --eval:

    (let ((org-mobile-files '("/path/to/tmpdir")))
      (require 'org-mobile nil 'noerror)
      (org-mobile-push))

org-mobile-directory is set to an scpx:... path so that the push
happens via TRAMP to my public server.  This all works fine.

However, when I run org-mobile-pull, edits to ~/org/notes/my-hobby.org
fail, and instead an error is appended to the file pointed to by
`org-mobile-inbox-for-pull', e.g.

    * Heading not found on level 1: journal F(edit:body) 
[[olp:my-hobby.org:journal][a heading]]

I have examined the code in org-mobile.el, and I'm pretty sure that
this is due to org-mobile-locate-entry containing the following code:

        ...
        (setq file (expand-file-name file org-directory))
        (setq path (mapcar 'org-link-unescape
                           (org-split-string path "/")))
        (org-find-olp (cons file path))))))

org-directory is ~/org, so it only succeeds in locating files which
live directly in ~/org.

Is this a known limitation, and if so, can anyone suggest a good way
to work around it?

Thanks!

Adam

Reply via email to