Skip to content
This repository has been archived by the owner on May 29, 2022. It is now read-only.

Commit

Permalink
Update arg for repo
Browse files Browse the repository at this point in the history
- Update arg for repo addressing from `--repo_addr` to `--name`.

Close #19
  • Loading branch information
aslamplr committed May 13, 2020
1 parent b79fcd5 commit a5ed8f1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,15 @@ struct Secrets {
)]
auth_token: String,
#[clap(
long = "repo_addr",
short = "r",
long = "name",
short = "n",
value_name = "OWNER/NAME",
about = "Repository address including the owner and name seperated by slash\nEg. aslamplr/gh-cli",
display_order = 1,
takes_value = true,
required = true
)]
repo_addr: String,
name: String,
#[clap(long = "action", short = "a", value_name = "ACTION", possible_values = &["list", "get", "add", "update", "delete"], display_order = 4, takes_value = true, required = true)]
action: String,
#[clap(long = "secret_key", value_name = "SECRET_KEY", takes_value = true, required_ifs = &[
Expand All @@ -72,14 +72,14 @@ async fn main() -> anyhow::Result<()> {
match opts.subcmd {
SubCommand::Secrets(secrets) => {
let Secrets {
repo_addr,
name,
auth_token,
action,
secret_key,
secret_value,
} = secrets;

let repo = RepoRequest::try_from(&repo_addr, &auth_token)?;
let repo = RepoRequest::try_from(&name, &auth_token)?;

match (action.as_ref(), secret_key, secret_value) {
("list", _, _) => {
Expand Down

0 comments on commit a5ed8f1

Please sign in to comment.