Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skate and charm/kv duplicate code #31

Open
toby opened this issue Apr 4, 2022 · 1 comment
Open

Skate and charm/kv duplicate code #31

toby opened this issue Apr 4, 2022 · 1 comment
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@toby
Copy link
Contributor

toby commented Apr 4, 2022

Skate and the charm kv command are currently nearly copy and paste clones of each other. This makes it hard to keep them in sync and is generally not a great idea. We should make a module that has all of the Cobra CLI code in one place and use it for both skate and charm kv. It probably makes sense to have that be a submodule of Skate that gets imported in the main.go for Skate and Charm.

@toby toby added the enhancement New feature or request label Apr 4, 2022
@bashbunni bashbunni added the good first issue Good for newcomers label May 5, 2022
@mishrasidhant
Copy link

mishrasidhant commented Jun 20, 2024

I've taken a crack at implementing these changes. As it currently stands both commands aren't 100% identical, specifically the list-db and delete-db sub-commands are not available for charm kv.

If we wish to keep it that way I can break the module out into just the overlapping sub commands and keep the db sub commands in skate only.

Otherwise the changes (in charm) would then include the addition of list-db and delete-db.

Not sure if this issue is the appropriate place to have these discussions. I can also put up a draft PR to showcase the changes in code if required, it's ready @toby

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants