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

refactor(cli.rs): signer and plugin subcommands, use new clap derive syntax #2928

Merged
merged 12 commits into from
Dec 9, 2021

Conversation

JonasKruckenberg
Copy link
Contributor

@JonasKruckenberg JonasKruckenberg commented Nov 20, 2021

Replaces runner structs with option structs that implement From<&ArgMatches> / TryFrom<ArgMatches> to clean things up a bit. This makes the code structure more scaleable imo.

This also splits the tauri sign subcommand into two: tauri signer sign and tauri signer generate.

TODO:

  • add tauri plugin add subcommand
  • update color scheme
  • add progress info tauri build
  • add progress info tauri dev
  • add progress info tauri signer
  • add input prompts to tauri plugin init

Notes to self:

enum ResourceDescriptor {
   Semver(Version),
   Registry {
      registry: Option<String>,
      version: Version,
   },
   Git {
      git: String,
      branch: Option<String>,
      commit: Option<String>,
      tag: Option<String>
}

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Docs
  • New Binding Issue #___
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:

Does this PR introduce a breaking change? (check one)

  • Yes. Issue #___
  • No

The PR fulfills these requirements:

  • When resolving a specific issue, it's referenced in the PR's title (e.g. fix: #xxx[,#xxx], where "xxx" is the issue number)
  • A change file is added if any packages will require a version bump due to this PR per the instructions in the readme.

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

Other information:

@lucasfernog lucasfernog changed the title Refactor cli refactor(cli.rs): signer and plugin subcommands, use new clap derive syntax Dec 9, 2021
@lucasfernog
Copy link
Member

@JonasKruckenberg I'll merge this PR because we need the clap update and it's a huge refactor already. If you're still interested in doing the other tasks, please open a new PR :) thanks for this amazing work, it really helped migrating to clap 3.0.0-rc.0

@lucasfernog lucasfernog marked this pull request as ready for review December 9, 2021 14:07
@lucasfernog lucasfernog requested a review from a team as a code owner December 9, 2021 14:07
@lucasfernog lucasfernog requested a review from a team December 9, 2021 14:07
@JonasKruckenberg
Copy link
Contributor Author

JonasKruckenberg commented Dec 9, 2021

Yes it's good to merge as is, I got stuck with the more involved features (that's in part where #3029 originated from) but that will have to continue on a separate branch anyway so 👍🏻 from me

@JonasKruckenberg JonasKruckenberg requested a review from a team December 9, 2021 14:57
@lucasfernog lucasfernog merged commit 1458ab3 into next Dec 9, 2021
@lucasfernog lucasfernog deleted the refactor/cli.rs branch December 9, 2021 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants