@outwalk/create-firefly 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +7 -14
  2. package/package.json +7 -7
package/dist/index.js CHANGED
@@ -92,10 +92,8 @@ function installDependencies(dependencies, directory) {
92
92
  const command = /^win/.test(process.platform) ? "npm.cmd" : "npm";
93
93
  const spawnProcess = (command2, args) => {
94
94
  const { status, error } = child_process.spawnSync(command2, args, { cwd: directory, stdio: "ignore" });
95
- if (status != 0)
96
- throw new Error("failed to install project dependencies.");
97
- if (error)
98
- throw error;
95
+ if (status != 0) throw new Error("failed to install project dependencies.");
96
+ if (error) throw error;
99
97
  };
100
98
  try {
101
99
  spawnProcess(command, ["install", "--save"].concat(dependencies));
@@ -184,8 +182,7 @@ const questions = [
184
182
  message: "The current directory is not empty. Continue?",
185
183
  initial: true
186
184
  });
187
- if (!response.continue)
188
- return;
185
+ if (!response.continue) return;
189
186
  }
190
187
  config.name = path.basename(process.cwd());
191
188
  settings.useCurrentDirectory = true;
@@ -230,14 +227,11 @@ const questions = [
230
227
  return;
231
228
  }
232
229
  try {
233
- if (!skipInstall)
234
- await installDependencies(dependencies, projectPath);
235
- if (!skipGit)
236
- await intitializeGitRepository(projectPath);
230
+ if (!skipInstall) await installDependencies(dependencies, projectPath);
231
+ if (!skipGit) await intitializeGitRepository(projectPath);
237
232
  } catch (error) {
238
233
  logger.error(error.message);
239
- if (!settings.useCurrentDirectory)
240
- TemplateBuilder.deleteDirectory(config.name);
234
+ if (!settings.useCurrentDirectory) TemplateBuilder.deleteDirectory(config.name);
241
235
  return;
242
236
  }
243
237
  console.log("\n----------------------------------");
@@ -245,8 +239,7 @@ const questions = [
245
239
  if (!settings.useCurrentDirectory) {
246
240
  console.log(firefly(` > cd ./${path.relative(process.cwd(), config.name)} `));
247
241
  }
248
- if (skipInstall)
249
- console.log(firefly(" > npm install"));
242
+ if (skipInstall) console.log(firefly(" > npm install"));
250
243
  console.log(firefly(" > npm run dev"));
251
244
  console.log("----------------------------------");
252
245
  })();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@outwalk/create-firefly",
3
- "version": "0.7.0",
3
+ "version": "0.8.0",
4
4
  "description": "Firefly - a modern scalable web framework.",
5
5
  "main": "dist/index.js",
6
6
  "publishConfig": {
@@ -44,14 +44,14 @@
44
44
  "yargs-parser": "^21.1.1"
45
45
  },
46
46
  "devDependencies": {
47
- "@eslint/js": "^9.1.1",
48
- "@rollup/plugin-commonjs": "^25.0.7",
47
+ "@eslint/js": "^9.4.0",
48
+ "@rollup/plugin-commonjs": "^25.0.8",
49
49
  "@rollup/plugin-json": "^6.1.0",
50
50
  "@rollup/plugin-node-resolve": "^15.2.3",
51
- "esbuild": "^0.20.2",
52
- "eslint": "^9.1.1",
53
- "globals": "^15.0.0",
54
- "rollup": "^4.16.4",
51
+ "esbuild": "^0.21.4",
52
+ "eslint": "^9.4.0",
53
+ "globals": "^15.3.0",
54
+ "rollup": "^4.18.0",
55
55
  "rollup-plugin-esbuild": "^6.1.1"
56
56
  }
57
57
  }