@@ -72,8 +72,6 @@ fn graceful_shutdown(st: &Mutex<ShutdownState>) {
7272}
7373
7474pub fn run ( cmd : DevCommand ) -> anyhow:: Result < ( ) > {
75- let playground_crate = "monoxide-font" ;
76- let playground_example = "playground" ;
7775 let playground_webui_dir = util:: playground_webui_dir ( ) ;
7876 let playground_webui_dist = util:: playground_webui_dist_dir ( ) ;
7977
@@ -122,13 +120,7 @@ pub fn run(cmd: DevCommand) -> anyhow::Result<()> {
122120 }
123121
124122 // Then start the playground server.
125- let playground_child = start_playground (
126- & cmd,
127- playground_crate,
128- playground_example,
129- webui_port,
130- & playground_webui_dist,
131- ) ?;
123+ let playground_child = start_playground ( & cmd, webui_port, & playground_webui_dist) ?;
132124 {
133125 // graceful shutdown stuff
134126 let mut st = shutdown_state. lock ( ) . unwrap ( ) ;
@@ -189,8 +181,6 @@ fn check_exit_status(shutdown_state: &Arc<Mutex<ShutdownState>>) -> bool {
189181
190182fn start_playground (
191183 cmd : & DevCommand ,
192- playground_crate : & str ,
193- playground_example : & str ,
194184 webui_port : Option < u16 > ,
195185 playground_webui_dir : & Path ,
196186) -> anyhow:: Result < Child > {
@@ -202,15 +192,7 @@ fn start_playground(
202192 playground_cmd = Command :: new ( "dx" ) ;
203193 playground_cmd. env ( "TELEMETRY" , "false" ) ;
204194 }
205- playground_cmd. args ( [
206- "serve" ,
207- "--hotpatch" ,
208- "-p" ,
209- playground_crate,
210- "--example" ,
211- playground_example,
212- "--features=playground" ,
213- ] ) ;
195+ playground_cmd. args ( [ "serve" , "--hotpatch" , "--example=playground" ] ) ;
214196 let mut playground_args = vec ! [ Cow :: from( "serve" ) , format!( "--port={}" , cmd. port) . into( ) ] ;
215197 if let Some ( webui_port) = webui_port {
216198 playground_args. push ( format ! ( "--reverse-proxy=http://127.0.0.1:{webui_port}" ) . into ( ) ) ;
0 commit comments