From 1928338bff56e6ce79e4b1b02f70b368783a9712 Mon Sep 17 00:00:00 2001 From: slamkode <46542905+slamkode@users.noreply.github.com> Date: Wed, 9 Jan 2019 23:00:48 +0100 Subject: [PATCH 1/2] Add does not contain operator *! --- youtube_dl/YoutubeDL.py | 1 + 1 file changed, 1 insertion(+) diff --git a/youtube_dl/YoutubeDL.py b/youtube_dl/YoutubeDL.py index 4493fd0e1..867b5102f 100755 --- a/youtube_dl/YoutubeDL.py +++ b/youtube_dl/YoutubeDL.py @@ -1067,6 +1067,7 @@ class YoutubeDL(object): '^=': lambda attr, value: attr.startswith(value), '$=': lambda attr, value: attr.endswith(value), '*=': lambda attr, value: value in attr, + '*!': lambda attr, value: value not in attr, } str_operator_rex = re.compile(r'''(?x) \s*(?Pext|acodec|vcodec|container|protocol|format_id) From b173f39d473d61ad95ac1f3b0d2e18d6a9a0a78c Mon Sep 17 00:00:00 2001 From: slamkode <46542905+slamkode@users.noreply.github.com> Date: Thu, 10 Jan 2019 19:34:23 +0100 Subject: [PATCH 2/2] Update README.md for new *! operator --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 901595444..115e4b30a 100644 --- a/README.md +++ b/README.md @@ -667,7 +667,7 @@ The following numeric meta fields can be used with comparisons `<`, `<=`, `>`, ` - `asr`: Audio sampling rate in Hertz - `fps`: Frame rate -Also filtering work for comparisons `=` (equals), `!=` (not equals), `^=` (begins with), `$=` (ends with), `*=` (contains) and following string meta fields: +Also filtering work for comparisons `=` (equals), `!=` (not equals), `^=` (begins with), `$=` (ends with), `*=` (contains), `*!` (does not contain) and following string meta fields: - `ext`: File extension - `acodec`: Name of the audio codec in use - `vcodec`: Name of the video codec in use