Fix setup.py (#8798)

enforce unix newline encoding regardless of OS creating the file
This commit is contained in:
Julien Plu 2020-11-27 18:25:20 +01:00 committed by GitHub
parent 03bddc375b
commit b0f2dbc594
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -165,7 +165,7 @@ class DepsTableUpdateCommand(Command):
]
target = "src/transformers/dependency_versions_table.py"
print(f"updating {target}")
with open(target, "w") as f:
with open(target, "w", encoding="utf-8", newline="\n") as f:
f.write("\n".join(content))