git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: David Woodhouse <dwmw2@infradead.org>,
	Martin Koegler <mkoegler@auto.tuwien.ac.at>
Cc: git@vger.kernel.org, Junio C Hamano <junkio@cox.net>
Subject: Re: gitweb - encoding problems
Date: Tue, 22 May 2007 09:50:34 +0200	[thread overview]
Message-ID: <200705220950.35493.jnareb@gmail.com> (raw)
In-Reply-To: <1179794012.2771.112.camel@shinybook.infradead.org>

On Thu, 22 May 2007, David Woodhouse wrote:
> On Mon, 2007-05-21 at 22:57 +0200, Martin Koegler wrote:

>> I use ISO-8859-1 as my locale, so my blobs, commits and tags are in
>> this encoding. 
> 
> That's a very strange thing for anyone to do in the 21st century.
> Did you configure this archaic thing correctly in .git/config?
> 
> Otherwise, gitweb will assume that you're using utf-8 like any normal
> person would, and of course you'll have problems when it tries to deal
> with your legacy character set as if it were something sensible.

Actually gitweb does not respect i18n.* configuration variables and
happily assumes that everything is in utf-8, with the exception of 
*_plain views, which are send :raw.

If you decide to implement supporting encodings other that utf-8 in 
gitweb, please remember that some (like git-show, git-log) but not all 
parts (like git-rev-list or --pretty=raw) do the decoding/encoding. And 
that git can be compiled without iconv support. And that comits might 
be in different encodings, which should be given by 'encoding' header, 
but there is no way to guess encoding for a blob, or for a file names.


git-commit(1):
 i18n.commitEncoding::
     Character encoding the commit messages are stored in; git itself
     does not care per se, but this information is necessary e.g. when
     importing commits from emails or in the gitk graphical history
     browser (and possibly at other places in the future or in other
     porcelains). See e.g. gitlink:git-mailinfo[1]. Defaults to 'utf-8'.

 i18n.logOutputEncoding::
     Character encoding the commit messages are converted to when
     running `git-log` and friends.

-- 
Jakub Narebski
Poland

      reply	other threads:[~2007-05-22 10:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-21 20:57 gitweb - encoding problems Martin Koegler
2007-05-21 21:09 ` Ismail Dönmez
2007-05-22  0:33 ` David Woodhouse
2007-05-22  7:50   ` Jakub Narebski [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200705220950.35493.jnareb@gmail.com \
    --to=jnareb@gmail.com \
    --cc=dwmw2@infradead.org \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    --cc=mkoegler@auto.tuwien.ac.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).