Note that there are some explanatory texts on larger screens.

plurals
  1. POMercurial commit messages and log, what encoding is supported, does Hg care at all?
    text
    copied!<p>I tried doing a simple commit through my wrapper library for Mercurial, using the simple text of <code>Unicode:æøåÆØÅ</code> as my commit message. This is written to a text file and given to Mercurial with the appropriate parameter:</p> <pre><code>hg commit --logfile FILE </code></pre> <p>If I subsequently look at the repository with TortoiseHg, the characters are reproduced correctly. On the Console, they are mangled:</p> <pre> [C:\Temp] :hg log changeset: 0:6a0911410128 tag: tip user: Lasse V. Karlsen date: Wed Dec 01 21:48:54 2010 +0100 summary: Unicode:├ª├╕├Ñ├å├ÿ├à </pre> <p>If I redirect the output of <code>hg log</code> to a file, and open it up, <code>æøåÆØÅ</code> is reproduced correctly.</p> <p>So, my question is this:</p> <ul> <li>Can I ask <code>hg</code> to write the log to a file directly, or do I have to redirect standard output?</li> <li>Will this cause problems with python encoding for console, ie. some characters will make <code>hg</code> crash instead of just mangling the output?</li> <li>Is there a known supported encoding for the commit messages that I should adhere to?</li> </ul> <p>Or is it just this simple:</p> <ul> <li>Mercurial doesn't care, it takes the contents of the file I give it, whatever the content, and stores that as the commit message. When producing the log, it will just dump it back to the console falling prey to whatever limitations the Python console output library has in this regard?</li> </ul>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload