Skip to content

Commit

Permalink
Update link_to_other_folder_files.py
Browse files Browse the repository at this point in the history
  • Loading branch information
fknives authored Jan 29, 2024
1 parent dcc0a56 commit 7a9195a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions link_to_other_folder_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ def rename_files(directory):
new_filename = new_filename.replace('\u00FA','u')
new_filename = new_filename.replace('\u00FC','u')
new_filename = new_filename.replace('\u0171','u')
# file specific cases (here example remove some prefix)
new_filename = re.sub(r'^[0-9_.()\s]+','',new_filename)

old_path = os.path.join(directory, filename)
new_path = os.path.join(directory, new_filename)
os.rename(old_path, new_path)
Expand Down

0 comments on commit 7a9195a

Please sign in to comment.