We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d0390c8 + 13ead7d commit 65aa1daCopy full SHA for 65aa1da
scripts/blacklist-extensions.lua
@@ -6,6 +6,7 @@ opts = {
6
}
7
(require 'mp.options').read_options(opts)
8
local msg = require 'mp.msg'
9
+local utils = require 'mp.utils'
10
11
function split(input)
12
local ret = {}
@@ -42,9 +43,13 @@ else
42
43
end
44
45
function should_remove(filename)
- if string.find(filename, "://") then
46
+
47
+ -- don't remove playlist entry if it's a stream or directory
48
+ local file = utils.file_info(filename)
49
+ if not file or file.is_dir then
50
return false
51
52
53
local extension = string.match(filename, "%.([^./]+)$")
54
if not extension and opts.remove_files_without_extension then
55
return true
0 commit comments