FyroxEngine / Fyrox

3D and 2D game engine written in Rust
https://fyrox.rs
MIT License
7.49k stars 340 forks source link

Cannot create a project with fyrox-template that starts with a number #530

Closed zment4 closed 9 months ago

zment4 commented 9 months ago

Trying to run fyrox-template init --name 2dtest results in the following error

thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: 
Os { code: 3, kind: NotFound, message: "The system cannot find the path specified." }'

After a few baffling minutes, I realized the error was because the name started with a number, and for whatever reason, that's a no-go. I quickly patched up the template source to return a clearer error message in case someone else tries to create a new project with a name starting with a number, and doesn't realize why it doesn't work. PR incoming.