I’ve got a Rust snap that is snapping fine, but is somewhat painful to rebuild, as any change to any file in the repository requires a full recompile. Is there any way to alleviate this? The two things I can think of would be:
- Some way of telling snapcraft that changes to e.g.
/docs/
doesn’t affect the Rust code at all.- This would have to be a manual process, since something like
build.rs
can read arbitrary files at compile time
- This would have to be a manual process, since something like
- The ability to do an incremental recompile
- I haven’t really dived into how the Rust plugin works, but I’m surprised this doesn’t happen already, given that snapcraft reuses the VM or container between builds.