Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// Write pattern readme
await sander.writeFile(readmeTarget, readmeData);
// Be nice and instructional
spinner.text = ` Initialized project ${data.name} at ${cwd}`;
spinner.succeed();
const instructions = [
process.cwd() !== cwd && `cd ${directory}`,
'npm install',
data.scripts.start === 'patternplate' ?
'npm start -- --open' : './node_modules/.bin/patternplate start --open'
].filter(Boolean);
const sep = defaultShell.includes('fish') ? '; and ' : ' && ';
console.log(`🚀 Start and open patternplate:`);
console.log(`\n ${instructions.join(sep)}`);
}
// Write pattern readme
await sander.writeFile(readmeTarget, readmeData);
// Be nice and instructional
spinner.text = ` Initialized project ${data.name} at ${cwd}`;
spinner.succeed();
const instructions = [
process.cwd() !== cwd && `cd ${directory}`,
"npm install",
data.scripts.start === "patternplate"
? "npm start -- --open"
: "./node_modules/.bin/patternplate start --open"
].filter(Boolean);
const sep = defaultShell.includes("fish") ? "; and " : " && ";
console.log(`🚀 Start and open patternplate:`);
console.log(`\n ${instructions.join(sep)}`);
}