[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] [PATCH] Escape slashes in ARCHIVE_OLPATH
From: |
Takafumi Arakaki |
Subject: |
Re: [O] [PATCH] Escape slashes in ARCHIVE_OLPATH |
Date: |
Fri, 9 Nov 2012 14:26:17 +0100 |
I am not familiar with org-mode test suite but I can try. Could you
tell me where I can find similar test cases which creates archive
entries?
---
Takafumi
On Fri, Nov 9, 2012 at 9:57 AM, Nicolas Goaziou <address@hidden> wrote:
> Hello,
>
> Takafumi Arakaki <address@hidden> writes:
>
>> Currently information about tree structure is lost if you have a slash
>> in node headings. This patch fixes the problem by escaping slashes in
>> headings before concatenating them.
>
> Thanks for your patch.
>
> Would you mind providing a test-case to illustrate the problem? Also,
> could you provide a change log entry for the patch (and use git
> format-patch if possible)?
>
>> + (olpath (mapconcat
>> + (lambda (s)
>> + (setq s (replace-regexp-in-string "\\\\" "\\\\\\\\" s))
>> + (setq s (replace-regexp-in-string "/" "\\\\/" s))
>> + s)
>
> I'd rather nest the `replace-regexp-in-string' instead of setq'ing twice
> in a row the same variable. I.e:
>
> (replace-regexp-in-string
> "/" "\\\\/" (replace-regexp-in-string "\\\\" "\\\\\\\\" s))
>
>
> Regards,
>
> --
> Nicolas Goaziou