emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: email@edgar-kalkowski.de
To: emacs-orgmode@gnu.org
Subject: [PATCH] Detect state changes correctly if todo state names contain German umlauts
Date: Fri, 8 Sep 2017 16:00:22 +0200	[thread overview]
Message-ID: <f560cfd2117bd1de3b4eb02dd313672e.squirrel@edgar-kalkowski.de> (raw)

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

Hello fellow org-moders,

as I am from Germany I use an umlaut in one of my org todo state names. I
noticed that state changes concerning that state are not picked up by the
org agenda view. This is due to umlauts missing from a regular expression
that is used to detect lines with state changes in them in the logbook
drawer.

To remedy this issue I propose to apply the appended patch.

Best regards,

Edgar

PS: Since I am not subscribed to the org mode mailing list please include
my mail address in any reply to this message.

[-- Attachment #2: 0001-org-agenda.el-Detect-state-changes-correctly-if-the-.patch --]
[-- Type: text/x-patch, Size: 1129 bytes --]

From 6a6e75f9d42b028fd39c79896b9e13f532c4a4ed Mon Sep 17 00:00:00 2001
From: Edgar Kalkowski <eMail@edgar-kalkowski.de>
Date: Fri, 8 Sep 2017 15:47:49 +0200
Subject: [PATCH] org-agenda.el: Detect state changes correctly if the todo
 state contains umlauts

* lisp/org/org-agenda.el (org-agenda-get-progress): Add typical German umlauts to the regexp detecting state changes.

TINYCHANGE
---
 lisp/org/org-agenda.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/org/org-agenda.el b/lisp/org/org-agenda.el
index 6ef333a..709e1ef 100644
--- a/lisp/org/org-agenda.el
+++ b/lisp/org/org-agenda.el
@@ -5780,7 +5780,7 @@ please use `org-class' instead."
 		(list
 		 (if (memq 'closed items) (concat "\\<" org-closed-string))
 		 (if (memq 'clock items) (concat "\\<" org-clock-string))
-		 (if (memq 'state items) "- State \"\\([a-zA-Z0-9]+\\)\".*?"))))
+		 (if (memq 'state items) "- State \"\\([a-zA-ZäöüÄÖÜß0-9]+\\)\".*?"))))
 	 (parts-re (if parts (mapconcat 'identity parts "\\|")
 		     (error "`org-agenda-log-mode-items' is empty")))
 	 (regexp (concat
-- 
2.14.1

             reply	other threads:[~2017-09-08 14:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-08 14:00 email [this message]
2017-09-08 19:20 ` [PATCH] Detect state changes correctly if todo state names contain German umlauts 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=f560cfd2117bd1de3b4eb02dd313672e.squirrel@edgar-kalkowski.de \
    --to=email@edgar-kalkowski.de \
    --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).