File tree Expand file tree Collapse file tree 2 files changed +19
-9
lines changed
Expand file tree Collapse file tree 2 files changed +19
-9
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ const checkGit = async () => {
2828const moveTxzFile = async ( txzPath : string , pluginVersion : string ) => {
2929 const txzName = getTxzName ( pluginVersion ) ;
3030 await rename ( txzPath , join ( deployDir , txzName ) ) ;
31- }
31+ } ;
3232
3333function updateEntityValue (
3434 xmlString : string ,
@@ -92,12 +92,17 @@ const buildPlugin = async ({
9292 */
9393
9494const main = async ( ) => {
95- const validatedEnv = await setupPluginEnv ( process . argv ) ;
96- await checkGit ( ) ;
97- await cleanupPluginFiles ( ) ;
95+ try {
96+ const validatedEnv = await setupPluginEnv ( process . argv ) ;
97+ await checkGit ( ) ;
98+ await cleanupPluginFiles ( ) ;
9899
99- await buildPlugin ( validatedEnv ) ;
100- await moveTxzFile ( validatedEnv . txzPath , validatedEnv . pluginVersion ) ;
100+ await buildPlugin ( validatedEnv ) ;
101+ await moveTxzFile ( validatedEnv . txzPath , validatedEnv . pluginVersion ) ;
102+ } catch ( error ) {
103+ console . error ( error ) ;
104+ process . exit ( 1 ) ;
105+ }
101106} ;
102107
103108await main ( ) ;
Original file line number Diff line number Diff line change @@ -88,9 +88,14 @@ const buildTxz = async (validatedEnv: TxzEnv) => {
8888} ;
8989
9090const main = async ( ) => {
91- const validatedEnv = await setupTxzEnv ( process . argv ) ;
92- await cleanupTxzFiles ( ) ;
93- await buildTxz ( validatedEnv ) ;
91+ try {
92+ const validatedEnv = await setupTxzEnv ( process . argv ) ;
93+ await cleanupTxzFiles ( ) ;
94+ await buildTxz ( validatedEnv ) ;
95+ } catch ( error ) {
96+ console . error ( error ) ;
97+ process . exit ( 1 ) ;
98+ }
9499} ;
95100
96101await main ( ) ;
You can’t perform that action at this time.
0 commit comments