g2-config: don't simply kill ~/.gitconfig, move it instead #2

Merged
merged 1 commit into from Jun 21, 2012

Conversation

Projects
None yet
2 participants
Contributor

snaewe commented Jun 21, 2012

Signed-off-by: Stefan Naewe stefan.naewe@gmail.com

@snaewe snaewe g2-config: don't simply kill ~/.gitconfig, move it instead
Signed-off-by: Stefan Naewe <stefan.naewe@gmail.com>
8f30650

@orefalo orefalo added a commit that referenced this pull request Jun 21, 2012

@orefalo orefalo Merge pull request #2 from snaewe/dont-kill-gitconfig
g2-config: don't simply kill ~/.gitconfig, move it instead
847b32d

@orefalo orefalo merged commit 847b32d into orefalo:master Jun 21, 2012

@orefalo orefalo pushed a commit that referenced this pull request Oct 25, 2012

@snaewe @patthoyts snaewe + patthoyts Update the git documentation submodule url.
In his latest "What's cooking in git.git" message (Nov 2011, #2; Sun, 6)
J.C.Hamano announced the availability of the documentation
branches (html, doc) in dedicated repositories at github.com.
Change .gitmodules to point 'doc/git/html' to the new repository.

Signed-off-by: Stefan Naewe <stefan.naewe@gmail.com>
Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
74e6e01

@orefalo orefalo pushed a commit that referenced this pull request Oct 25, 2012

@atnak atnak vimrc: Set UTF-8 as vim's default encoding for commit messages
We avoid setting `encoding' and `termencoding', and opt to only setting
`fileencodings' because it's understood that vim sets the former two to
the user's system's "ANSI" and "OEM" code pages (setting either both if
they differ or only `encoding' if they're the same) [1].  The setting of
"OEM" is particularly significant as it is required for native characters
to be correctly displayed on the user's console [2].

We set "utf-8" as the only value of `fileencodings', there by making it
the default encoding used to save new commit messages to COMMIT_EDITMSG.
This is consistent with what git expects in an environment where the
user has not altered the value of `i18n.commitencoding'.

When loading an existing message, for operations such as 'commit --amend'
and 'rebase -i', our setting for `fileencodings' means that vim will first
attempt to load it as UTF-8 and then fallback to the encoding set by
`encoding' if unable to do so.  This encoding is expected to be "ANSI",
as mentioned above, and this side-effect is of benefit if the user does
have an altered value of `i18n.commitencoding'.  (Here, we're assuming
users not set this, if at all, to anything other than that of "ANSI"
because that is thought to be the most natural for their location.)

Users SHOULD unset `i18n.commitencoding' after this is released.  However,
failing to do so may not show any visible regressions.  (See tests for
case #2 at [3].)

This patch follows the discussion in the [4] link.

[1] http://groups.google.com/group/msysgit/msg/be6218f1cbf5e747
[2] http://groups.google.com/group/vim_dev/msg/3dd77f3014a60e43
[3] http://groups.google.com/group/msysgit/msg/508cca8b57f00546
[4] http://groups.google.com/group/msysgit/msg/55c582fb1b279d08
ee24d5b

snaewe deleted the unknown repository branch May 15, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment