[Bug 4714] New: regression in escaping { in templates

mercurial-bugs at selenic.com mercurial-bugs at selenic.com
Mon Jun 8 07:47:19 UTC 2015


http://bz.selenic.com/show_bug.cgi?id=4714

          Priority: normal
            Bug ID: 4714
                CC: mercurial-devel at selenic.com
          Assignee: bugzilla at selenic.com
           Summary: regression in escaping { in templates
          Severity: bug
    Classification: Unclassified
                OS: Linux
          Reporter: alberto.griggio at gmail.com
          Hardware: PC
            Status: UNCONFIRMED
           Version: 3.4.1
         Component: templater
           Product: Mercurial

It seems that escaping { characters in templates is (partially) broken in
3.4.1.
Using:

  hg log --template "{if(bookmarks, '\\{{bookmarks}}  ')}\n"

used to work up to 3.4, but raises a ParseError in 3.4.1.

Here's a quick way of reproducing:

  $ mkdir hgtest
  $ cd hgtest/
  $ hg init
  $ echo "foo" > foo.txt
  $ hg add foo.txt
  $ hg book test-book
  $ hg ci -m "added foo"
  $ hg log --template "{if(bookmarks, '\\{{bookmarks}}  ')}\n"

hg: parse error at 2: syntax error

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Mercurial-devel mailing list