Rewrite PathFilter

Added filter options:
- dot (replace leading dot with _)
- posix (replace illegal chars in *nix OSes with _)
- vfat (replace illegal chars in VFAT filesystems with _)
- whitespace (replace all whitespace chars with _)
- printable (replace all non printable ASCII chars with _)

Removed filter options:
- fat (replaced with vfat)
- special

Fixes #313.

Signed-off-by: JoeLametta <JoeLametta@users.noreply.github.com>
This commit is contained in:
JoeLametta
2018-11-03 13:00:00 +00:00
parent afc31f930e
commit 4dc02ec12e
4 changed files with 86 additions and 57 deletions

View File

@@ -70,8 +70,11 @@ class Program:
d = {}
for key, default in list({
'fat': True,
'special': False
'dot': True,
'posix': True,
'vfat': False,
'whitespace': False,
'printable': False
}.items()):
value = None
value = self._config.getboolean('main', 'path_filter_' + key)