yutannihilation / savvy

A simple R extension interface using Rust
https://yutannihilation.github.io/savvy/guide/
MIT License
63 stars 3 forks source link

Feature Request: `savvy-cli build --for-cran` #286

Closed t-kalinowski closed 1 week ago

t-kalinowski commented 1 month ago

It would be helpful to have a command in savvy-cli that simplifies the process of preparing an R source package for CRAN. Currently, getting a savvy-using package ready for CRAN involves additional steps like vendoring Rust dependencies, updating Makevars, configuring cargo settings, and generating an authors file.

A build --for-cran command could help by automating these extra steps while keeping the standard package development process with savvy straightforward.

yutannihilation commented 1 month ago

In general, I'm strongly against encouraging innocent users to submit their Rust-powered package to CRAN, which leads them to a lot of troubles. To be clear, it's totally possible to use Rust in CRAN packages, but I believe it's expert-only. For example, typical problems they face are

Both cannot be automatically fixed by such a command. So, it's inappropriate to advertise "CRAN-ready".

That said, I'm curious why you wanted this feature. If you want to vendor the source on building the package, prqlr's setup might help.

https://github.com/PRQL/prqlc-r

yutannihilation commented 1 week ago

Closing this for now. Please let me know if you need some specific feature to get your package on CRAN!

t-kalinowski commented 1 week ago

Thanks! Sorry for not getting back to you sooner. I will need this eventually and will be happy to work on it when that time comes.