mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-03-11 22:05:47 +01:00
Allow full path names to be matched by 'wildignore'.
Closes issue #567.
This commit is contained in:
@@ -1613,8 +1613,9 @@
|
|||||||
<default>&option.wildignore.default;</default>
|
<default>&option.wildignore.default;</default>
|
||||||
<description>
|
<description>
|
||||||
<p>
|
<p>
|
||||||
List of file patterns to ignore when completing files. For example,
|
List of path name patterns to ignore when completing files and
|
||||||
the following will ignore object files and Vim swap files:
|
directories. For example, the following will ignore object files
|
||||||
|
and Vim swap files:
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<set opt="wildignore"><str delim="'">\.o$</str>,<str delim="'">^\..*\.s[a-z]{2}$</str></set>
|
<set opt="wildignore"><str delim="'">\.o$</str>,<str delim="'">^\..*\.s[a-z]{2}$</str></set>
|
||||||
|
|||||||
@@ -907,10 +907,8 @@ unlet s:cpo_save
|
|||||||
};
|
};
|
||||||
context.compare = function (a, b) b.isdir - a.isdir || String.localeCompare(a.text, b.text);
|
context.compare = function (a, b) b.isdir - a.isdir || String.localeCompare(a.text, b.text);
|
||||||
|
|
||||||
if (modules.options["wildignore"]) {
|
if (modules.options["wildignore"])
|
||||||
let wig = modules.options.get("wildignore");
|
context.filters.push(function (item) !modules.options.get("wildignore").getKey(item.path));
|
||||||
context.filters.push(function (item) item.isdir || !wig.getKey(item.path));
|
|
||||||
}
|
|
||||||
|
|
||||||
// context.background = true;
|
// context.background = true;
|
||||||
context.key = dir;
|
context.key = dir;
|
||||||
@@ -1077,7 +1075,7 @@ unlet s:cpo_save
|
|||||||
options["shellcmdflag"];
|
options["shellcmdflag"];
|
||||||
|
|
||||||
options.add(["wildignore", "wig"],
|
options.add(["wildignore", "wig"],
|
||||||
"List of file patterns to ignore when completing file names",
|
"List of path name patterns to ignore when completing files and directories",
|
||||||
"regexplist", "");
|
"regexplist", "");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user