diff --git a/index.js b/index.js index 249c618..bca04cf 100644 --- a/index.js +++ b/index.js @@ -87,7 +87,7 @@ const getProfiles = () => { const content = fs.readFileSync(profilePath, 'utf-8'); content .split(os.EOL) - .filter(line => /^#/.test(line) === false || line.length > 0) + .filter(line => /^[#]/.test(line) === false && line.length > 0) .forEach(line => { const ch = line.trim()[0]; if (ch === '[') { @@ -102,6 +102,7 @@ const getProfiles = () => { profiles.push(profile); } else { if (!profile) { + console.log(`Found ${ch} instead of [`); throw new Error('You must profile a profile name in []'); } profile.ligatures.push(line);