emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ian Dunn <dunni@gnu.org>
To: emacs-orgmode@gnu.org
Subject: MobileOrg Export Broken
Date: Thu, 23 Jun 2016 20:57:02 -0400	[thread overview]
Message-ID: <871t3nxv35.fsf@gnu.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 616 bytes --]


    I run Org from the git repo, updating daily.  I unsuccessfully tried syncing with MobileOrg (Android) about two hours ago.  I reverted org-mobile.el back to the version from yesterday and found the problem: TODO keywords aren't being listed correctly.  Here's an example:

Old:
#+TODO: TODO | DEFERRED DONE PENDING CANCELLED

New:
#+TODO: TODO

    This messes with MobileOrg, preventing it from syncing.

    I worked through the problem, which appears to be caused by org-delete-all being called before the TODO keywords are inserted into the file.  I attached a patch that fixes this problem.

-- 
Ian Dunn


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: org-mobile.el.patch --]
[-- Type: text/x-diff, Size: 585 bytes --]

diff --git a/lisp/org-mobile.el b/lisp/org-mobile.el
index 9c69128..9192561 100644
--- a/lisp/org-mobile.el
+++ b/lisp/org-mobile.el
@@ -446,8 +446,9 @@ agenda view showing the flagged items."
 				      x))
 			     (cdr entry)))
 	       (dwds (or (member "|" kwds) (last kwds)))
-	       (twds (org-delete-all dwds kwds)))
+	       (twds kwds))
 	  (insert "#+TODO: " (mapconcat 'identity kwds " ") "\n")
+	  (org-delete-all dwds twds)
 	  (setq todo-kwds (org-delete-all twds todo-kwds))
 	  (setq done-kwds (org-delete-all dwds done-kwds))))
       (when (or todo-kwds done-kwds)

             reply	other threads:[~2016-06-24  0:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-24  0:57 Ian Dunn [this message]
2016-06-24  7:22 ` MobileOrg Export Broken Nicolas Goaziou

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

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=871t3nxv35.fsf@gnu.org \
    --to=dunni@gnu.org \
    --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 public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).