hex icon indicating copy to clipboard operation
hex copied to clipboard

Add `hex.registry add` Command

Open aj-foster opened this issue 4 years ago • 4 comments

This PR supersedes #920. See that PR for previous discussion.

In this PR, we add a mix hex.registry add command to the existing mix task. The purpose of this command is to allow private registry maintainers to add one or more packages to an existing registry without necessarily having all of the package tarballs present.

At the time or writing, this PR is a minimal effort for the purpose of discussion. We have an opportunity to make larger changes to the hex.registry task to support future growth, if desired.

Some topics to consider:

  • Do you have any recommendations for error messages when, for example, someone attempts to add a non-existent tarball?
  • Should we support adding a package that matches one already in the registry?
  • Should we create separate (and more granular) functions for reading and writing local registries, for the purpose of reuse as we add additional commands in the future (e.g. remove, retire)?
  • Should we provide test setup helpers, such as create_local_registry or even an in_local_registry macro?

With your guidance, I'm happy to contribute towards the right solution for the long term.

aj-foster avatar Dec 14 '21 03:12 aj-foster

Hi @aj-foster! What's the status of this PR?

ericmj avatar Nov 02 '22 11:11 ericmj

Hi @ericmj I still need to respond to your comments and make changes based on the merged changes to hex_core. Apologies for not cleaning this up sooner.

aj-foster avatar Nov 07 '22 15:11 aj-foster

@aj-foster No worries, just checking in to get the status. I will leave the PR open and you can get to it if you get the time. Thank you! 💜

ericmj avatar Nov 07 '22 16:11 ericmj

Hi @ericmj — Made some updates to this PR. Hopefully I re-understood everything correctly, since it's been a while. 🙂 Just a few comments in the above threads to make sure I'm on the right track.

aj-foster avatar Nov 12 '22 05:11 aj-foster