step5j(word) { let result = word; const match = /^(.+?)(ησε|ησου|ησα)$/.exec(result); if (match) { [, result] = match; if (/^(ν|χερσον|δωδεκαν|ερημον|μεγαλον|επταν|ι)$/.test(result)) { result += 'ησ'; } } return result; }
const gitVersion = async () => { const {stdout} = await execa('git', ['version']); const match = /git version (?<version>\d+\.\d+\.\d+).*/.exec(stdout); return match && match.groups.version; }
test('webpack import resolver is used if webpack.config.js is found', async t => { const cwd = 'fixtures/webpack/with-config/'; const {results} = await fn.lintFiles(path.resolve(cwd, 'file1.js'), { cwd, rules: { 'import/no-unresolved': 2 } }); t.is(results[0].errorCount, 1); const errorMessage = results[0].messages[0].message; t.truthy(/Unable to resolve path to module 'inexistent'/.exec(errorMessage)); });
forEachLine(lineMetadata(), function (line, lineIndex, inCode) { if (!inCode && /^#+[^#\s]/.test(line) && !/#\s*$/.test(line) && !line.startsWith("#️⃣")) { var hashCount = /^#+/.exec(line)[0].length; addErrorContext(onError, lineIndex + 1, line.trim(), null, null, [1, hashCount + 1], { "editColumn": hashCount + 1, "insertText": " " }); } });
filterTokens(params, "heading_open", function (token) { if (headingStyleFor(token) === "atx") { var line = token.line, lineNumber = token.lineNumber; var match = /^(#+)(\s{2,})(?:\S)/.exec(line); if (match) { var hashLength = match[1]["length"], spacesLength = match[2]["length"]; addErrorContext(onError, lineNumber, line.trim(), null, null, [1, hashLength + spacesLength + 1], { "editColumn": hashLength + 1, "deleteCount": spacesLength - 1 }); } } });
/* * Helper to cleanse path */ const cleanLine = (line = '') => { const m = /.*\((.*)\).?/.exec(line) || []; return m[1] ? line.replace(m[1], _.last(m[1].split(path.sep))) : line; }
transformToSafeString(input) { if (/^[\d]/g.exec(input)) { return `model${input}`; } // NOTICE: add dash to get proper snake/pascal case if (this.isReservedWord(input)) { return `model${_.upperFirst(input)}`; } return input; }
step3a(word) { const match = /^(.+?)(ειο|ειοσ|ειοι|εια|ειασ|ειεσ|ειου|ειουσ|ειων)$/.exec( word ); return match && match[1].length > 4 ? match[1] : word; }
const parseBranch = buf => { const match = /ref: refs\/heads\/([^\n]+)/.exec(buf.toString()); return match ? match[1] : null; }
step5m(word) { let result = word; const match = /^(.+?)(ουμε|ησουμε|ηθουμε)$/.exec(result); if (match) { [, result] = match; if (/^(παρασουσ|φ|χ|ωριοπλ|αζ|αλλοσουσ|ασουσ)$/.test(result)) { result += 'ουμ'; } } return result; }
step2b(word) { const match = /^(.+?)(εδεσ|εδων)$/.exec(word); if (match) { let result = match[1]; if (/(οπ|ιπ|εμπ|υπ|γηπ|δαπ|κρασπ|μιλ)$/.test(result)) { result += 'εδ'; } return result; } return word; }
step2d(word) { const match = /^(.+?)(εωσ|εων|εασ|εα)$/.exec(word); if (match) { let result = match[1]; if (/^(θ|δ|ελ|γαλ|ν|π|ιδ|παρ|στερ|ορφ|ανδρ|αντρ)$/.test(result)) { result += 'ε'; } return result; } return word; }
step5l(word) { let result = word; const match = /^(.+?)(ουνε|ησουνε|ηθουνε)$/.exec(result); if (match) { [, result] = match; if (/^(ν|ρ|σπι|στραβομουτσ|κακομουτσ|εξων)$/.test(result)) { result += 'ουν'; } } return result; }
step5e(word) { let result = word; const match = /^(.+?)(ομαστε|ιομαστε)$/.exec(result); if (match) { [, result] = match; if (/^ον$/.test(result)) { result += 'ομαστ'; } } return result; }
step5k(word) { let result = word; const match = /^(.+?)(ηστε)$/.exec(result); if (match) { [, result] = match; if ( /^(ασβ|σβ|αχρ|χρ|απλ|αειμν|δυσχρ|ευχρ|κοινοχρ|παλιμψ)$/.test(result) ) { result += 'ηστ'; } } return result; }