| 1141 | exports.minimatch.filter = exports.filter; |
| 1142 | var ext = (a, b = {}) => Object.assign({}, a, b); |
| 1143 | var defaults = (def) => { |
| 1144 | if (!def || typeof def !== "object" || !Object.keys(def).length) { |
| 1145 | return exports.minimatch; |
| 1146 | } |
| 1147 | const orig = exports.minimatch; |
| 1148 | const m = (p, pattern, options = {}) => orig(p, pattern, ext(def, options)); |
| 1149 | return Object.assign(m, { |
| 1150 | Minimatch: class Minimatch extends orig.Minimatch { |
| 1151 | constructor(pattern, options = {}) { |
| 1152 | super(pattern, ext(def, options)); |
| 1153 | } |
| 1154 | static defaults(options) { |
| 1155 | return orig.defaults(ext(def, options)).Minimatch; |
| 1156 | } |
| 1157 | }, |
| 1158 | AST: class AST extends orig.AST { |
| 1159 | /* c8 ignore start */ |
| 1160 | constructor(type, parent, options = {}) { |
| 1161 | super(type, parent, ext(def, options)); |
| 1162 | } |
| 1163 | /* c8 ignore stop */ |
| 1164 | static fromGlob(pattern, options = {}) { |
| 1165 | return orig.AST.fromGlob(pattern, ext(def, options)); |
| 1166 | } |
| 1167 | }, |
| 1168 | unescape: (s, options = {}) => orig.unescape(s, ext(def, options)), |
| 1169 | escape: (s, options = {}) => orig.escape(s, ext(def, options)), |
| 1170 | filter: (pattern, options = {}) => orig.filter(pattern, ext(def, options)), |
| 1171 | defaults: (options) => orig.defaults(ext(def, options)), |
| 1172 | makeRe: (pattern, options = {}) => orig.makeRe(pattern, ext(def, options)), |
| 1173 | braceExpand: (pattern, options = {}) => orig.braceExpand(pattern, ext(def, options)), |
| 1174 | match: (list, pattern, options = {}) => orig.match(list, pattern, ext(def, options)), |
| 1175 | sep: orig.sep, |
| 1176 | GLOBSTAR: exports.GLOBSTAR |
| 1177 | }); |
| 1178 | }; |
| 1179 | exports.defaults = defaults; |
| 1180 | exports.minimatch.defaults = exports.defaults; |
| 1181 | var braceExpand = (pattern, options = {}) => { |