summaryrefslogtreecommitdiffstats
path: root/git-show.html
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2015-08-03 12:43:00 -0700
committerJunio C Hamano <gitster@pobox.com>2015-08-03 12:43:00 -0700
commitd7ed4041c8468a2ca93f1c8ac511af9d895d3d6d (patch)
treef209ad1e994b76de43073839fe78c6d431f60e02 /git-show.html
parent2ce0aac108b9c935f3ac01e98478120df1f52ce1 (diff)
downloadgit-htmldocs-d7ed4041c8468a2ca93f1c8ac511af9d895d3d6d.tar.gz
Autogenerated HTML docs for v2.5.0-234-gefc8a
Diffstat (limited to 'git-show.html')
-rw-r--r--git-show.html36
1 files changed, 24 insertions, 12 deletions
diff --git a/git-show.html b/git-show.html
index e428ae018..dbbe59857 100644
--- a/git-show.html
+++ b/git-show.html
@@ -2580,29 +2580,41 @@ two unresolved merge parents with the working tree file
<div class="sect1">
<h2 id="_discussion">Discussion</h2>
<div class="sectionbody">
-<div class="paragraph"><p>At the core level, Git is character encoding agnostic.</p></div>
+<div class="paragraph"><p>Git is to some extent character encoding agnostic.</p></div>
<div class="ulist"><ul>
<li>
<p>
-The pathnames recorded in the index and in the tree objects
- are treated as uninterpreted sequences of non-NUL bytes.
- What readdir(2) returns are what are recorded and compared
- with the data Git keeps track of, which in turn are expected
- to be what lstat(2) and creat(2) accepts. There is no such
- thing as pathname encoding translation.
+The contents of the blob objects are uninterpreted sequences
+ of bytes. There is no encoding translation at the core
+ level.
</p>
</li>
<li>
<p>
-The contents of the blob objects are uninterpreted sequences
- of bytes. There is no encoding translation at the core
- level.
+Path names are encoded in UTF-8 normalization form C. This
+ applies to tree objects, the index file, ref names, as well as
+ path names in command line arguments, environment variables
+ and config files (<code>.git/config</code> (see <a href="git-config.html">git-config(1)</a>),
+ <a href="gitignore.html">gitignore(5)</a>, <a href="gitattributes.html">gitattributes(5)</a> and
+ <a href="gitmodules.html">gitmodules(5)</a>).
</p>
+<div class="paragraph"><p>Note that Git at the core level treats path names simply as
+sequences of non-NUL bytes, there are no path name encoding
+conversions (except on Mac and Windows). Therefore, using
+non-ASCII path names will mostly work even on platforms and file
+systems that use legacy extended ASCII encodings. However,
+repositories created on such systems will not work properly on
+UTF-8-based systems (e.g. Linux, Mac, Windows) and vice versa.
+Additionally, many Git-based tools simply assume path names to
+be UTF-8 and will fail to display other encodings correctly.</p></div>
</li>
<li>
<p>
-The commit log messages are uninterpreted sequences of non-NUL
- bytes.
+Commit log messages are typically encoded in UTF-8, but other
+ extended ASCII encodings are also supported. This includes
+ ISO-8859-x, CP125x and many others, but <em>not</em> UTF-16/32,
+ EBCDIC and CJK multi-byte encodings (GBK, Shift-JIS, Big5,
+ EUC-x, CP9xx etc.).
</p>
</li>
</ul></div>