1- import chalk from 'chalk' ;
2- import { spawnSync } from 'child_process' ;
3- import { Command } from 'commander/esm.mjs' ;
4- import envinfo from 'envinfo' ;
5- import fs from 'fs-extra' ;
6- import inquirer from 'inquirer' ;
7- import os from 'os' ;
8- import path from 'path' ;
1+ import chalk from 'chalk' ;
2+ import { spawnSync } from 'child_process' ;
3+ import { Command } from 'commander/esm.mjs' ;
4+ import envinfo from 'envinfo' ;
5+ import fs from 'fs-extra' ;
6+ import inquirer from 'inquirer' ;
7+ import os from 'os' ;
8+ import path from 'path' ;
9+ import { sanitizeInput } from './util/Sanitizer.mjs' ;
10+
911
1012const __dirname = path . resolve ( ) ,
1113 cwd = process . cwd ( ) ,
@@ -18,13 +20,7 @@ const __dirname = path.resolve(),
1820 neoPath = path . resolve ( packageJson . name . includes ( 'neo.mjs' ) ? './' : './node_modules/neo.mjs/' ) ,
1921 webpackPath = path . resolve ( neoPath , 'buildScripts/webpack' ) ,
2022 programName = `${ packageJson . name } buildAll` ,
21- questions = [ ] ,
22- sanitizeInput = value => {
23- if ( typeof value === 'string' ) {
24- return value . replace ( / ^ [ " ' ] | [ " ' ] $ / g, '' ) . trim ( ) ;
25- }
26- return value ;
27- } ;
23+ questions = [ ] ;
2824
2925program
3026 . name ( programName )
0 commit comments