Skip to content

Commit 8e7a3d7

Browse files
committed
Fixes overridePrefix being passed into lib from CLI
1 parent a93d9ed commit 8e7a3d7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cli.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ program.version(pkg.version)
88
.usage('[options] <name>')
99
.option('-p, --prefix <prefix>',
1010
'The prefix for the library (Default: `RN`)')
11+
.option('--override-prefix',
12+
'Overrides the prefix check and allows the name to begin with uppercase characters')
1113
.option('--module-prefix <modulePrefix>',
1214
'The module prefix for the library (Default: `react-native`)')
1315
.option('--package-identifier <packageIdentifier>',
@@ -25,6 +27,7 @@ const modulePrefix = program.modulePrefix;
2527
const packageIdentifier = program.packageIdentifier;
2628
const namespace = program.namespace;
2729
const platforms = (program.platforms) ? program.platforms.split(',') : program.platforms;
30+
const overridePrefix = program.overridePrefix;
2831

2932
const beforeCreation = Date.now();
3033
createLibrary({
@@ -34,6 +37,7 @@ createLibrary({
3437
packageIdentifier,
3538
platforms,
3639
namespace,
40+
overridePrefix,
3741
}).then(() => {
3842
console.log(`
3943
Created library ${name}. It took ${Date.now() - beforeCreation}ms.`);

0 commit comments

Comments
 (0)