leptos-rs / cargo-leptos

Build tool for Leptos (Rust)
MIT License
315 stars 88 forks source link

Respect Cargo target directory configuration #159

Closed tyoeer closed 8 months ago

tyoeer commented 10 months ago

Changes:

Didn't manage to add additional regression tests:

Additional notes/things to look at that are outside the scope of this PR:

tyoeer commented 10 months ago

Had to temporarily remove my own target-dir configuration to make it match the CI, but the tests look like they should match what the CI is expecting now.

tyoeer commented 9 months ago

As a general comment, could you please include a sample dev experience walkthrough of how to leverage these improvements? This way I don't have to guess if I did the right set up to verify changes are doing what they are intended to accomplish.

@aperepel The easiest way to test everything would be to configure the target directory in the top-level cargo configuration in ~/.cargo/config.toml, for example with:

[build]
target-dir = ".cargo/targetShare"

This shares the target directory between projects. I personally do this to speed up compilation and save disk-usage by re-using already compiled dependencies (between projects), other people might have other reasons.

With this configuration, one would expect that:

(Ideally there'd be a test demonstrating all this, but see my original PR comment for why I didn't manage to make one)

Maneren commented 8 months ago

Hello, what's the status here? I've been using a binary compiled from this PR for quite some time now (without any issues) and I'd love to see this merged so I can use other updates as well. Is there anything I can help with? (code, testing, review, ...)

gbj commented 8 months ago

Sorry for the delay here — I've been reviewing PRs post-0.5 and am going to start going through these now.

Maneren commented 8 months ago

No worries, thank you