Skip to content
Snippets Groups Projects
Commit c2f1fdbb authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Scripts:

- Updated file mode update in update_license_headers.py script
parent 0989a478
No related branches found
No related tags found
2 merge requests!235Release TeraFlowSDN 3.0,!224Resolve "Update license headers for Release 3"
......@@ -87,7 +87,7 @@ def process_file(
temp_file_path = file_path + '.temp'
replaced = False
file_mode = os.stat(file_path)
file_stat = os.stat(file_path)
try:
with open(file_path, encoding='UTF-8') as source:
with open(temp_file_path, 'w', encoding='UTF-8') as target:
......@@ -104,7 +104,7 @@ def process_file(
file_updated.write(file_path + '\n')
os.rename(temp_file_path, file_path)
os.chmod(file_path, file_mode)
os.chmod(file_path, file_stat.st_mode)
def main() -> int:
with open(FILE_PATH_NO_HEADER, 'w', encoding='UTF-8') as file_no_header:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment