Skip to content

Commit

Permalink
Win, gitpython-developers#519: Ensure fixtures & bashscript checked-o…
Browse files Browse the repository at this point in the history
…ut eol=lf

+ FIX all Diff TCs.
  • Loading branch information
ankostis committed Sep 28, 2016
1 parent e61439b commit 4cede23
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ install:
#
- |
uname -a
where git git-daemon python pip
where git git-daemon python pip pip3 pip34
python --version
python -c "import struct; print(struct.calcsize('P') * 8)"
Expand Down
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
git/test/fixtures/* eol=lf
init-tests-after-clone.sh
4 changes: 2 additions & 2 deletions git/compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ class UnicodeMixin(object):
"""Mixin class to handle defining the proper __str__/__unicode__
methods in Python 2 or 3."""

if sys.version_info[0] >= 3: # Python 3
if PY3:
def __str__(self):
return self.__unicode__()
else: # Python 2
def __str__(self):
return self.__unicode__().encode('utf8')
return self.__unicode__().encode(defenc)
2 changes: 1 addition & 1 deletion git/index/fun.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def run_commit_hook(name, index):
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
cwd=index.repo.working_dir,
close_fds=(is_posix),
close_fds=is_posix,
creationflags=PROC_CREATIONFLAGS,)
stdout, stderr = cmd.communicate()
cmd.stdout.close()
Expand Down

0 comments on commit 4cede23

Please sign in to comment.