emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Jonathan Leech-Pepin <jonathan.leechpepin@gmail.com>
To: Alan Schmitt <alan.schmitt@polytechnique.org>
Cc: emacs-orgmode <emacs-orgmode@gnu.org>
Subject: Re: how to replace 'org-drawers'
Date: Mon, 6 Oct 2014 11:13:51 -0400	[thread overview]
Message-ID: <CAEWDx5dgMAu2Mq9rki8iy21R5uqdbJ1LcR_KhVHjuqS1bFcBQg@mail.gmail.com> (raw)
In-Reply-To: <m2lhotmloi.fsf@charm-wifi.irisa.fr>

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

Hello Alan

On 6 October 2014 08:23, Alan Schmitt <alan.schmitt@polytechnique.org>
wrote:

> Hello,
>
> I'm trying to use org-wc, but it fails because org-drawers no longer
> exists. Is there a suggestion to change
> https://github.com/dato/org-wc/blob/master/org-wc.el#L55 such that it
> works with current org?
>
>
A quick search for variables reveals `org-drawer-regexp` [ "^[
]*:\\(\\(?:\\w\\|[-_]\\)+\\):[     ]*$" ]

It matches both the name of the drawer and `:END:`.

So the function could be adapted to use `org-drawer-regexp` instead
(untested but should match to the next :END:):

((looking-at org-drawer-regexp)
 (while (or (eobp)
            (not (looking-at ":END:")))
   (re-search-forward org-drawer-regexp nil t)))

Regards,
Jonathan


> Thanks,
>
> Alan
>
> --
> OpenPGP Key ID : 040D0A3B4ED2E5C7
>

[-- Attachment #2: Type: text/html, Size: 1613 bytes --]

  parent reply	other threads:[~2014-10-06 15:14 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-06 12:23 how to replace 'org-drawers' Alan Schmitt
2014-10-06 12:56 ` Thorsten Jolitz
2014-10-06 16:50   ` Alan Schmitt
2014-10-06 15:00 ` Rasmus
2014-10-06 16:52   ` Alan Schmitt
2014-10-06 15:13 ` Jonathan Leech-Pepin [this message]
2014-10-06 17:21   ` Alan Schmitt

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=CAEWDx5dgMAu2Mq9rki8iy21R5uqdbJ1LcR_KhVHjuqS1bFcBQg@mail.gmail.com \
    --to=jonathan.leechpepin@gmail.com \
    --cc=alan.schmitt@polytechnique.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).