leptos-rs / cargo-leptos

Build tool for Leptos (Rust)
MIT License
314 stars 87 forks source link

bin_exe override #237

Closed sjud closed 4 months ago

sjud commented 4 months ago

If your bin name is different then your package name you'll get a missing file error.

Error: at `/Users/sam/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-leptos-0.2.5/src/command/serve.rs:8:46`

Caused by:
    0: at `/Users/sam/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-leptos-0.2.5/src/compile/server.rs:39:22`
    1: at `/Users/sam/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-leptos-0.2.5/src/service/site.rs:117:44`
    2: Could not read "target/debug/leptos_chat_app" at `/Users/sam/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cargo-leptos-0.2.5/src/ext/fs.rs:44:10`
    3: No such file or directory (os error 2)

But this pull request adds a bin-exe parameter which you can use to change the output file name.

benwis commented 4 months ago

Thanks for the PR! Can you make this a bit more verbose, perhaps bin-exe-name?

sjud commented 4 months ago

Thanks for the PR! Can you make this a bit more verbose, perhaps bin-exe-name?

Done! Thanks!