make-mp-data 2.0.12 → 2.0.13
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/index.js +3 -2
- package/lib/cli/cli.js +4 -3
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -454,12 +454,13 @@ if (isCLI) {
|
|
|
454
454
|
(async () => {
|
|
455
455
|
const cliConfig = getCliParams();
|
|
456
456
|
|
|
457
|
-
// Load dungeon config
|
|
457
|
+
// Load dungeon config - default to simple mode if no mode specified
|
|
458
458
|
let finalConfig = cliConfig;
|
|
459
459
|
if (cliConfig.complex) {
|
|
460
460
|
const complexConfig = await import('./dungeons/complex.js');
|
|
461
461
|
finalConfig = { ...complexConfig.default, ...cliConfig };
|
|
462
|
-
} else if (cliConfig.simple) {
|
|
462
|
+
} else if (cliConfig.simple || (!cliConfig.complex && !cliConfig.simple)) {
|
|
463
|
+
// Default to simple mode when no flags or when --simple is explicitly set
|
|
463
464
|
const simpleConfig = await import('./dungeons/simple.js');
|
|
464
465
|
finalConfig = { ...simpleConfig.default, ...cliConfig };
|
|
465
466
|
}
|
package/lib/cli/cli.js
CHANGED
|
@@ -28,9 +28,10 @@ function cliParams() {
|
|
|
28
28
|
.usage(`\nusage:\nnpx $0 [dataModel.js] [options]
|
|
29
29
|
|
|
30
30
|
examples:
|
|
31
|
-
npx $0
|
|
32
|
-
npx $0 --
|
|
33
|
-
npx $0
|
|
31
|
+
npx $0 (uses simple data model by default)
|
|
32
|
+
npx $0 --complex (full enterprise data model)
|
|
33
|
+
npx $0 --token 1234 --u 100 --e 1000 (send data to mixpanel)
|
|
34
|
+
npx $0 myDataConfig.js (use custom config)
|
|
34
35
|
|
|
35
36
|
DOCS: https://github.com/ak--47/make-mp-data
|
|
36
37
|
DATA MODEL: https://github.com/ak--47/make-mp-data/blob/main/default.js
|