irondash / cargokit

Integrate cargo build with flutter plugins and applications.
Other
61 stars 19 forks source link

When will cargokit be published to pub.dev? #39

Open fzyzcjy opened 1 year ago

fzyzcjy commented 1 year ago

Hi, I find this package and it seems to be quite interesting - it was nontrivial to set up a Rust+Flutter project in the old days! Therefore, I wonder when will it be published to pub.dev? (A quick search does not seem to show any results yet.) I am hoping to integrate it into flutter_rust_bridge as one of the ways to build a sample project.

P.S. You have many more merged PRs into Flutter than me! I only have 19 (flutter/engine) + 55 (flutter/flutter), but this number need to exclude some tiny ones (mainly shown in the title, especially the first page).

knopp commented 1 year ago

Cargokit is not meant to be published to pub.dev. As it currently works it is meant to be part of the plugin (or target app) through git subtree (optionally submodule for apps).

The process is documented here:

https://matejknopp.com/post/flutter_plugin_in_rust_with_no_prebuilt_binaries/

This allows non-dart parts of the plugin on depend on cargokit directly. This will likely change in future when dart native assets are ready.

fzyzcjy commented 1 year ago

I see, thank you!

Originally I thought, by publishing to pub.dev, I could make it a dependency, such that the pub.dev metrics such as popularity will faithfully reflect the number of people using it. Given that it should be be a submodule, I will explicitly state that the build system is using cargokit in the documentation.

fzyzcjy commented 11 months ago

By the way, a small revisit to this thread after I know a bit more about cargokit: If I understand correctly, build_tool package is the part that auto configures the toolchain and compiles everything (and is the main remaining part after native_assets are stablized), and the other scripts are glues to call build_tool from the specific platforms. Therefore, I guess one way is to publish build_tool to pub.dev, while the glues is still copied / submoduled into all projects.

knopp commented 11 months ago

I plan to publish build_tool once native assets are stabilized. Until then it seems like needless complication that would make it difficult to keep build_tool with the rest of cargokit in sync.

fzyzcjy commented 11 months ago

Looking forward to it!