Skip to content

Commit e3d3dff

Browse files
committed
feat: update
1 parent 9fa5ff9 commit e3d3dff

2 files changed

Lines changed: 25 additions & 7 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@quarkd/cli",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"description": "",
55
"type": "module",
66
"bin": {

src/index.js

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ function emptyDir(dir) {
5959

6060

6161
async function init() {
62+
const start = Date.now();
6263
const argTargetDir = formatTargetDir(argv._[0]);
6364
let targetDir = argTargetDir || defaultTargetDir;
6465

@@ -124,15 +125,32 @@ async function init() {
124125
}
125126
console.log(data);
126127

127-
// console.log(`\nScaffolding project in ${root}`);
128-
129-
console.log(chalk.green('\nInstalling dependencies...'));
128+
console.log(chalk.blue('\nInstalling dependencies...\n'));
130129

131130
sh.exec(
132-
`cd ${path.basename(root)} && npm install`
131+
`cd ${path.basename(root)} && npm install && clear`
133132
);
134-
console.log(chalk.green(`\n You can start the project with:`));
135-
console.log(chalk.green(`\n npm run dev`));
133+
134+
const end = Date.now();
135+
console.log(`\n ✨ Done in ${(end - start) / 1000}s\n`);
136+
137+
console.log(`Success!`)
138+
console.log(`Inside that directory, you can run several commands:\n`)
139+
140+
console.log(` ${chalk.blue('npm run dev')}`)
141+
console.log(` Starts the development server.\n`)
142+
143+
console.log(` ${chalk.blue('npm run build')}`)
144+
console.log(` Bundles the component inro static files for production.\n`)
145+
146+
console.log(` ${chalk.blue('npm run test')}`)
147+
console.log(` Starts the test runner.\n`)
148+
149+
console.log(` We suggest that you begin by typing:\n`);
150+
console.log(` ${chalk.blue(`\n cd`)} ${path.basename(root)}`);
151+
console.log(` ${chalk.blue(`\n npm run dev`)}\n`);
152+
153+
console.log('Happy hacking!');
136154
});
137155
}
138156

0 commit comments

Comments
 (0)