Adjust demo to be runnable in workspace

main
Elnu 1 year ago
parent 4430accee7
commit e8e5f4eef5

@ -1,3 +1,13 @@
fn main() {
renrs_gui::run("demo.rpy".into());
use std::env;
fn main() -> Result<(), std::io::Error> {
let mut path = env::current_exe()?; // /target/debug/renrs-demo
path.pop(); // /target/debug
path.pop(); // /target
path.pop(); // /
path.push("demo/demo.rpy"); // /demo/demo.rpy
renrs_gui::run(path);
Ok(())
}

Loading…
Cancel
Save