aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Library/IgnorePatterns.cs
diff options
context:
space:
mode:
authorAnthony Lavado <anthony@lavado.ca>2020-07-26 15:34:15 -0700
committerJoshua M. Boniface <joshua@boniface.me>2020-07-27 18:53:09 -0400
commit3e742e99a5951bb75c77f65f6f095affcb705982 (patch)
tree69aecec1251f81692f888a0ae9a0b55507236361 /Emby.Server.Implementations/Library/IgnorePatterns.cs
parentad3a96267e3c167bd2b5f61a17cda8b0b0f1f431 (diff)
Merge pull request #3704 from oddstr13/pr-dotdir-sample-1
Don't ignore dot directories or movies/episodes with sample in their name. (cherry picked from commit 6eb3e736c61d787fd3d6b98001916f0d9afe9719) Signed-off-by: Joshua M. Boniface <joshua@boniface.me>
Diffstat (limited to 'Emby.Server.Implementations/Library/IgnorePatterns.cs')
-rw-r--r--Emby.Server.Implementations/Library/IgnorePatterns.cs23
1 files changed, 20 insertions, 3 deletions
diff --git a/Emby.Server.Implementations/Library/IgnorePatterns.cs b/Emby.Server.Implementations/Library/IgnorePatterns.cs
index 6e6ef1359..e30a67593 100644
--- a/Emby.Server.Implementations/Library/IgnorePatterns.cs
+++ b/Emby.Server.Implementations/Library/IgnorePatterns.cs
@@ -18,7 +18,21 @@ namespace Emby.Server.Implementations.Library
{
"**/small.jpg",
"**/albumart.jpg",
- "**/*sample*",
+
+ // We have neither non-greedy matching or character group repetitions, working around that here.
+ // https://github.com/dazinator/DotNet.Glob#patterns
+ // .*/sample\..{1,5}
+ "**/sample.?",
+ "**/sample.??",
+ "**/sample.???", // Matches sample.mkv
+ "**/sample.????", // Matches sample.webm
+ "**/sample.?????",
+ "**/*.sample.?",
+ "**/*.sample.??",
+ "**/*.sample.???",
+ "**/*.sample.????",
+ "**/*.sample.?????",
+ "**/sample/*",
// Directories
"**/metadata/**",
@@ -64,10 +78,13 @@ namespace Emby.Server.Implementations.Library
"**/.grab/**",
"**/.grab",
- // Unix hidden files and directories
- "**/.*/**",
+ // Unix hidden files
"**/.*",
+ // Mac - if you ever remove the above.
+ // "**/._*",
+ // "**/.DS_Store",
+
// thumbs.db
"**/thumbs.db",