Removing ! character from file names.

This commit is contained in:
Roland 2022-08-15 12:17:40 -06:00
parent f94837299d
commit 1ede5f3f55
No known key found for this signature in database
GPG key ID: 9D6DBD3ACF11AB93
2 changed files with 2 additions and 1 deletions

View file

@ -739,7 +739,7 @@ def walk(path: Path) -> Generator[Path, None, None]:
# These characters are invalid in Windows or Linux.
INVALID_FILE_CHARS = re.compile(r'[/<>:\|"\\\?\*%]')
INVALID_FILE_CHARS = re.compile(r'[/<>:\|"\\\?\*%!]')
def escape_file_name(name: str) -> str:

View file

@ -292,6 +292,7 @@ def test_zig_zag(low, high, expected):
('foo*', 'foo'),
('foo&', 'foo&'),
('foo%', 'foo'),
('foo!', 'foo'),
]
)
def test_escape_file_name(name, expected):