dart-lang / native

Dart packages related to FFI and native assets bundling.
BSD 3-Clause "New" or "Revised" License
153 stars 43 forks source link

[native_assets_cli] Package name #999

Open dcharkes opened 7 months ago

dcharkes commented 7 months ago

After we add support for hook/link.dart we'll have a LinkConfig and LinkOutput that will share some types with the BuildConfig and BuildOutput.

And after adding DataAssets we'll have more assets than CCodeAssets/NativeCodeAssets.

So, the question is what this package should be renamed to:

Original tracking issue:

cc @mosuem @mkustermann

mkustermann commented 7 months ago

Would it make sense to go away from "native" and from "assets" and instead use package:dart_build / package:dbuild / ...?

dcharkes commented 7 months ago

dart_build still doesn't cover a link hook.

I think I'd prefer build_hook over dart_build, it's more clearly connected the "hook"s (https://github.com/dart-lang/sdk/issues/54334).

What's a good name for the "build hook" and "link hook"? (I think they should live in the same package, as they will have many shared classes.)

dcharkes commented 7 months ago

Notes from discussion with @mosuem

(package:compilation_hooks/build.dart was rejected because compilation_hooks is hard to connect with build.dart and link.dart)

mosuem commented 7 months ago

Throwing some nice not-as-technical names in the ring: package:weave or package:forge (my personal favorite).

dcharkes commented 3 months ago

From discussion with @mkustermann @HosseinYousefi @mosuem:

Which might conflict with package:hooks (11 years old, not update in 10 years). Maybe that package can be deprecated.

HosseinYousefi commented 3 months ago

I like package:hook.

@influx6 Would you mind transferring the ownership of your package:hooks to us? I don't want any confusion with package:hook.

cc/ @jonasfj

influx6 commented 3 months ago

@HosseinYousefi I need an email to use to transfer to

influx6 commented 3 months ago

I sent the invite to dc.harkes@gmail.com

HosseinYousefi commented 3 months ago

I sent the invite to [redacted].

We can move this conversation to email. I think @mosuem had already contacted you, let's talk about the correct email there.

dcharkes commented 3 months ago

I sent the invite to dc.harkes@gmail.com

Thanks @influx6! I have accepted the invite. 👍

@jonasfj Is marking the package:hooks discontinued enough for us to be able to upload a new package:hook?

dcharkes commented 3 months ago

@influx6 You might want to update the readme on the repo that it's discontinued and archive the GitHub repo.

Given that the SDK constraint is <2.0.0, I presume at this point we have 0 users. 😄 (The current Dart SDK releases can only run 2.12 and higher.) So we might even retract the whole package to avoid users making a typo in their pubspec and getting an error that they need Dart 1 instead of package:hooks not existing.

jonasfj commented 3 months ago

@jonasfj Is marking the package:hooks discontinued enough for us to be able to upload a new package:hook?

No, it's not.

pub.dev will generally, not allow publication of hook if hooks exist (and vice versa). This just some arbitrary rules we have in place to disallow similar package names. Exceptions to the rules on similar package names can be granted on a case by case basis.

The rules on similar package names are there to prevent typo squatting attacks. But if we can see that it's not an attack, we can make exemptions on a case by case basis.

In a case like this, where:

Formally, this is done by adding hook to reserved package name list: https://github.com/dart-lang/pub-dev/blob/b786b24ebea84705d0ba6c13b11a9e6f8d72a0c2/app/lib/package/overrides.dart#L9

Once deployed a Googler can create the package, and transfer it the people who requested it be created. In this case, that'd be you, so really you could just create it.