File tree Expand file tree Collapse file tree 3 files changed +15
-10
lines changed Expand file tree Collapse file tree 3 files changed +15
-10
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ ' @codeshift/cli ' : patch
3+ ---
4+
5+ Fix entrypoint
Original file line number Diff line number Diff line change 2222 "monorepo:check" : " manypkg check" ,
2323 "monorepo:fix" : " manypkg fix && preconstruct fix" ,
2424 "init:codemods" : " ts-node packages/initializer/src/index.ts" ,
25- "start:codemods" : " ts- node packages/cli/src/index.ts " ,
25+ "start:codemods" : " node packages/cli/bin/codeshift-cli.js " ,
2626 "validate:codemods" : " ts-node packages/validator/src/index.ts ./community" ,
2727 "release:codemods" : " ts-node packages/publisher/src/index.ts ./community ./.tmp" ,
2828 "prerelease" : " yarn validate && yarn test" ,
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ if (dev && !require.extensions['.ts']) {
1111 require ( 'ts-node' ) . register ( { project } ) ;
1212}
1313
14- require ( path . join ( '..' , dev ? 'src/cli' : 'dist/codeshift-cli.cjs.js' ) )
15- . run ( )
16- . catch ( error => {
17- if ( typeof error === 'number' ) {
18- process . exit ( error ) ;
19- }
20- console . error ( error ) ;
21- process . exit ( 1 ) ;
22- } ) ;
14+ try {
15+ require ( path . join ( '..' , dev ? 'src/index' : 'dist/codeshift-cli.cjs.js' ) ) ;
16+ } catch ( error ) {
17+ if ( typeof error === 'number' ) {
18+ process . exit ( error ) ;
19+ }
20+ console . error ( error ) ;
21+ process . exit ( 1 ) ;
22+ }
You can’t perform that action at this time.
0 commit comments