Shyam Kumar Sundarakumar
Shyam Kumar Sundarakumar

Reputation: 5787

Mercurial - cleverencode - cleverdecode - multiple file patterns - mercurial.ini

How do I specify the CRLF encode/decode option in mercurial.ini in Windows?

The documentation gives the following options:

[extensions]
win32text =
[decode]
** = cleverdecode:
[encode]
** = cleverencode:

for all files and,

[extensions]
win32text =
[decode]
**.txt = cleverdecode:
[encode]
**.txt= cleverencode:

for one kind of files (here .txt files).

What I need is to specify *.xml, *.java etc!

Upvotes: 2

Views: 997

Answers (1)

Martin Geisler
Martin Geisler

Reputation: 73808

Add more lines to the [decode] and [encode] sections:

[extensions]
win32text =

[decode]
**.txt = cleverdecode:
**.java = cleverdecode:
**.xml = cleverdecode:

[encode]
**.txt = cleverencode:
**.java = cleverencode:
**.xml = cleverencode:

By the way, the double-star matches any path and spans directory separators. See hg help patterns for more information about the so-called "globbing" options in Mercurial.

Upvotes: 4

Related Questions