Server IP : 162.213.251.212 / Your IP : 18.117.100.86 [ Web Server : LiteSpeed System : Linux business55.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : allssztx ( 535) PHP Version : 8.1.31 Disable Function : NONE Domains : 1 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /proc/self/root/home/allssztx/public_html/easybuyer/node_modules/micromatch/lib/ |
Upload File : |
'use strict'; var nanomatch = require('nanomatch'); var extglob = require('extglob'); module.exports = function(snapdragon) { var compilers = snapdragon.compiler.compilers; var opts = snapdragon.options; // register nanomatch compilers snapdragon.use(nanomatch.compilers); // get references to some specific nanomatch compilers before they // are overridden by the extglob and/or custom compilers var escape = compilers.escape; var qmark = compilers.qmark; var slash = compilers.slash; var star = compilers.star; var text = compilers.text; var plus = compilers.plus; var dot = compilers.dot; // register extglob compilers or escape exglobs if disabled if (opts.extglob === false || opts.noext === true) { snapdragon.compiler.use(escapeExtglobs); } else { snapdragon.use(extglob.compilers); } snapdragon.use(function() { this.options.star = this.options.star || function(/*node*/) { return '[^\\\\/]*?'; }; }); // custom micromatch compilers snapdragon.compiler // reset referenced compiler .set('dot', dot) .set('escape', escape) .set('plus', plus) .set('slash', slash) .set('qmark', qmark) .set('star', star) .set('text', text); }; function escapeExtglobs(compiler) { compiler.set('paren', function(node) { var val = ''; visit(node, function(tok) { if (tok.val) val += (/^\W/.test(tok.val) ? '\\' : '') + tok.val; }); return this.emit(val, node); }); /** * Visit `node` with the given `fn` */ function visit(node, fn) { return node.nodes ? mapVisit(node.nodes, fn) : fn(node); } /** * Map visit over array of `nodes`. */ function mapVisit(nodes, fn) { var len = nodes.length; var idx = -1; while (++idx < len) { visit(nodes[idx], fn); } } }