File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ async function watchMain(): Promise<void> {
1515 await context . watch ( ) ;
1616 await context . serve ( { servedir : "./dist/" } ) ;
1717}
18- async function watchDictionary ( ) : Promise < never > {
18+ async function watchDictionary ( ) : Promise < number > {
1919 const command = new Deno . Command ( Deno . execPath ( ) , {
2020 args : [
2121 "run" ,
@@ -36,12 +36,13 @@ async function watchDictionary(): Promise<never> {
3636 const process = command . spawn ( ) ;
3737 const status = await process . status ;
3838 assert ( ! status . success ) ;
39- Deno . exit ( status . code ) ;
39+ return status . code ;
4040}
4141if ( import . meta. main ) {
4242 if ( ! await exists ( new URL ( "../dictionary/dictionary.ts" , import . meta. url ) ) ) {
4343 const Dictionary = await import ( "../dictionary/build.ts" ) ;
4444 await Dictionary . build ( ) ;
4545 }
46- await Promise . all ( [ watchDictionary ( ) , watchMain ( ) ] ) ;
46+ const [ statusCode ] = await Promise . all ( [ watchDictionary ( ) , watchMain ( ) ] ) ;
47+ Deno . exit ( statusCode ) ;
4748}
You can’t perform that action at this time.
0 commit comments