SpacetimeDB icon indicating copy to clipboard operation
SpacetimeDB copied to clipboard

CLI: Search upwards for `Cargo.toml` to detect `--project-path`

Open bfops opened this issue 9 months ago • 1 comments

Several CLI subcommands (publish, build, generate, possibly others) attempt to determine whether the project is Rust or C# by looking for a Cargo.toml file in the current directory (or the --project-path if passed), and assume C# if the Cargo.toml is not found. This is a bad system and should be changed, but at the very least, they should search up for the Cargo.toml so that it's possible to run the commands from a subdirectory of a Rust project (e.g. in src/).

bfops avatar Mar 07 '25 18:03 bfops

We improved the language inference behavior here: https://github.com/clockworklabs/SpacetimeDB/pull/2218

We still only look in the current directory, though.

bfops avatar Mar 11 '25 06:03 bfops