git-config fileEncoding
Accept arbitrarily encoded repository filepaths etc when reading git config output. This fixes support for remotes with unusual characters in their names. For example, a remote with a url of /tmp/çüş was previously skipped, because the filename wasn't encoded right so it didn't think it was available. And when setting the annex-uuid of a remote named "çüş", it used to add it under a mis-encoded form of the remote's name. Both these cases now work ok in my testing.
This commit is contained in:
parent
1093d82f6b
commit
6f45827fe0
2 changed files with 7 additions and 0 deletions
|
@ -54,6 +54,10 @@ read' repo = go repo
|
||||||
{- Reads git config from a handle and populates a repo with it. -}
|
{- Reads git config from a handle and populates a repo with it. -}
|
||||||
hRead :: Repo -> Handle -> IO Repo
|
hRead :: Repo -> Handle -> IO Repo
|
||||||
hRead repo h = do
|
hRead repo h = do
|
||||||
|
-- We use the FileSystemEncoding when reading from git-config,
|
||||||
|
-- because it can contain arbitrary filepaths (and other strings)
|
||||||
|
-- in any encoding.
|
||||||
|
fileEncoding h
|
||||||
val <- hGetContentsStrict h
|
val <- hGetContentsStrict h
|
||||||
store val repo
|
store val repo
|
||||||
|
|
||||||
|
|
3
debian/changelog
vendored
3
debian/changelog
vendored
|
@ -6,6 +6,9 @@ git-annex (3.20120625) UNRELEASED; urgency=low
|
||||||
* Avoid ugly failure mode when moving content from a local repository
|
* Avoid ugly failure mode when moving content from a local repository
|
||||||
that is not available.
|
that is not available.
|
||||||
* Got rid of the last place that did utf8 decoding.
|
* Got rid of the last place that did utf8 decoding.
|
||||||
|
* Accept arbitrarily encoded repository filepaths etc when reading
|
||||||
|
git config output. This fixes support for remotes with unusual characters
|
||||||
|
in their names.
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Mon, 25 Jun 2012 11:38:12 -0400
|
-- Joey Hess <joeyh@debian.org> Mon, 25 Jun 2012 11:38:12 -0400
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue