File tree Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -16,18 +16,21 @@ fn main() {
16
16
] {
17
17
println ! ( "cargo:rerun-if-changed={tracked_file}" ) ;
18
18
}
19
- let vite_status = Command :: new ( "yarn" )
19
+
20
+ let mut vite_command = Command :: new ( "yarn" ) ;
21
+ vite_command
20
22
. arg ( "run" )
21
23
. arg ( "build" )
22
24
. arg ( "--outDir" )
23
25
. arg ( & vite_out_dir)
24
26
. arg ( "--base" )
25
- . arg ( "/ui/" )
26
- . status ( )
27
- . unwrap ( ) ;
28
- if !vite_status. success ( ) {
29
- panic ! ( "web-ui build failed: {vite_status}" ) ;
30
- }
27
+ . arg ( "/ui/" ) ;
28
+ let vite_status = vite_command. status ( ) ;
29
+ match vite_status {
30
+ Ok ( vite_status) if vite_status. success ( ) => { }
31
+ _ => panic ! ( "web-ui build failed: command {vite_command:?} resulted in {vite_status:?}" ) ,
32
+ } ;
33
+
31
34
let mut asset_map = phf_codegen:: Map :: new ( ) ;
32
35
for asset_file in vite_out_dir. join ( "assets" ) . read_dir ( ) . unwrap ( ) {
33
36
let asset_file = asset_file. unwrap ( ) ;
You can’t perform that action at this time.
0 commit comments