create-nextspark-app 0.1.0-beta.79 → 0.1.0-beta.80
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.
- package/dist/index.js +5 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -81,6 +81,9 @@ async function createProject(options) {
|
|
|
81
81
|
if (preset) {
|
|
82
82
|
initArgs.push("--preset", preset);
|
|
83
83
|
}
|
|
84
|
+
if (options.type) {
|
|
85
|
+
initArgs.push("--type", options.type);
|
|
86
|
+
}
|
|
84
87
|
if (options.name) {
|
|
85
88
|
initArgs.push("--name", options.name);
|
|
86
89
|
}
|
|
@@ -157,7 +160,7 @@ async function getProjectOptions(projectName, skipPrompts) {
|
|
|
157
160
|
// src/index.ts
|
|
158
161
|
var pkg = JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf-8"));
|
|
159
162
|
var program = new Command();
|
|
160
|
-
program.name("create-nextspark-app").description("Create a new NextSpark SaaS project").version(pkg.version).argument("[project-name]", "Name of the project").option("--preset <preset>", "Use a preset (saas, blog, crm)").option("--name <name>", "Project name (non-interactive mode)").option("--slug <slug>", "Project slug (non-interactive mode)").option("--description <desc>", "Project description (non-interactive mode)").option("--theme <theme>", "Theme to use (default, blog, crm, productivity, none)").option("--plugins <plugins>", "Plugins to install (comma-separated)").option("-y, --yes", "Skip prompts and use defaults", false).action(async (projectName, options) => {
|
|
163
|
+
program.name("create-nextspark-app").description("Create a new NextSpark SaaS project").version(pkg.version).argument("[project-name]", "Name of the project").option("--preset <preset>", "Use a preset (saas, blog, crm)").option("--type <type>", "Project type: web or web-mobile").option("--name <name>", "Project name (non-interactive mode)").option("--slug <slug>", "Project slug (non-interactive mode)").option("--description <desc>", "Project description (non-interactive mode)").option("--theme <theme>", "Theme to use (default, blog, crm, productivity, none)").option("--plugins <plugins>", "Plugins to install (comma-separated)").option("-y, --yes", "Skip prompts and use defaults", false).action(async (projectName, options) => {
|
|
161
164
|
console.log();
|
|
162
165
|
console.log(chalk2.bold.cyan(" NextSpark"));
|
|
163
166
|
console.log(chalk2.dim(" Create a new SaaS project"));
|
|
@@ -167,6 +170,7 @@ program.name("create-nextspark-app").description("Create a new NextSpark SaaS pr
|
|
|
167
170
|
await createProject({
|
|
168
171
|
...projectOptions,
|
|
169
172
|
preset: options.preset,
|
|
173
|
+
type: options.type,
|
|
170
174
|
name: options.name,
|
|
171
175
|
slug: options.slug,
|
|
172
176
|
description: options.description,
|