Skip to content
This repository has been archived by the owner on Oct 16, 2021. It is now read-only.

Commit

Permalink
use cp command instead of shutil.copy2 from python
Browse files Browse the repository at this point in the history
The copy2 function from python does not copy the file in it's original
encoding. If the source file is tagged as IBM-1047, the destination
file will be in ISO8859-1 encoding AND untagged.
Once python(2.7.13) is fixed, we can undo this.
  • Loading branch information
jBarz committed May 23, 2018
1 parent 4940bd4 commit b5dd012
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tools/install.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ def try_copy(path, dst):
print 'installing %s' % target_path
try_mkdir_r(os.path.dirname(target_path))
try_unlink(target_path) # prevent ETXTBSY errors
return os.system('cp %s %s' % (source_path, target_path)) # Remove when python is fixed
return shutil.copy2(source_path, target_path)

def try_remove(path, dst):
Expand Down

0 comments on commit b5dd012

Please sign in to comment.