From c3b675c13284c6c7fa2127d2d4e66752c3bab30d Mon Sep 17 00:00:00 2001 From: Mick Grove Date: Wed, 22 Oct 2025 16:30:32 -0700 Subject: [PATCH] =?UTF-8?q?-=20Added=20provider-specific=20kingfisher=20sc?= =?UTF-8?q?an=20subcommands=20(for=20example=20kingfisher=20scan=20github?= =?UTF-8?q?=20=E2=80=A6)=20that=20translate=20into=20the=20legacy=20flags?= =?UTF-8?q?=20under=20the=20hood.=20The=20new=20layout=20keeps=20backwards?= =?UTF-8?q?=20compatibility=20while=20removing=20the=20wall=20of=20provide?= =?UTF-8?q?r=20options=20from=20kingfisher=20scan=20--help.=20-=20Updated?= =?UTF-8?q?=20the=20README=20so=20every=20provider=20example=20(GitHub,=20?= =?UTF-8?q?GitLab,=20Bitbucket,=20Azure=20Repos,=20Gitea,=20Hugging=20Face?= =?UTF-8?q?,=20Slack,=20Jira,=20Confluence,=20S3,=20GCS,=20Docker)=20uses?= =?UTF-8?q?=20the=20new=20subcommand=20style.=20-=20Restored=20the=20direc?= =?UTF-8?q?t=20kingfisher=20scan=20/path/to/dir=20flow=20for=20local=20fil?= =?UTF-8?q?esystem=20scans=20while=20adding=20a=20--list-only=20switch=20t?= =?UTF-8?q?o=20each=20provider=20subcommand=20so=20repository=20enumeratio?= =?UTF-8?q?n=20no=20longer=20requires=20the=20standalone=20github=20repos,?= =?UTF-8?q?=20gitlab=20repos,=20etc.=20commands.=20-=20Removed=20the=20leg?= =?UTF-8?q?acy=20top-level=20provider=20commands=20(kingfisher=20github,?= =?UTF-8?q?=20kingfisher=20gitlab,=20kingfisher=20gitea,=20kingfisher=20bi?= =?UTF-8?q?tbucket,=20kingfisher=20azure,=20kingfisher=20huggingface)=20no?= =?UTF-8?q?w=20that=20enumeration=20lives=20under=20kingfisher=20scan=20=20--list-only.=20-=20Fixed=20kingfisher=20scan=20githu?= =?UTF-8?q?b=20=E2=80=A6=20(and=20other=20provider-specific=20subcommands)?= =?UTF-8?q?=20so=20they=20no=20longer=20demand=20placeholder=20path=20argu?= =?UTF-8?q?ments=20before=20the=20CLI=20accepts=20the=20request.=20-=20Rem?= =?UTF-8?q?oved=20the=20--bitbucket-username,=20--bitbucket-token,=20and?= =?UTF-8?q?=20--bitbucket-oauth-token=20flags=20in=20favour=20of=20KF=5FBI?= =?UTF-8?q?TBUCKET=5F*=20environment=20variables=20when=20authenticating?= =?UTF-8?q?=20to=20Bitbucket.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/cli/commands/scan.rs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/cli/commands/scan.rs b/src/cli/commands/scan.rs index 8e837d2..1402f47 100644 --- a/src/cli/commands/scan.rs +++ b/src/cli/commands/scan.rs @@ -9,10 +9,10 @@ use crate::{ cli::{ commands::{ azure::AzureRepoSpecifiers, - bitbucket::{BitbucketRepoSpecifiers, BitbucketRepoType}, + bitbucket::BitbucketRepoSpecifiers, gitea::GiteaRepoSpecifiers, - github::{GitHubRepoSpecifiers, GitHubRepoType}, - gitlab::{GitLabRepoSpecifiers, GitLabRepoType}, + github::GitHubRepoSpecifiers, + gitlab::GitLabRepoSpecifiers, huggingface::HuggingFaceRepoSpecifiers, inputs::{ContentFilteringArgs, InputSpecifierArgs}, output::{OutputArgs, ReportOutputFormat}, @@ -207,7 +207,7 @@ impl ScanCommandArgs { scan_args.input_specifier_args.git_url = args.git_url; None } - ScanInputCommand::Github(mut args) => { + ScanInputCommand::Github(args) => { if args.specifiers.is_empty() { bail!( "Specify at least one --user, --org, or use --all-orgs when scanning GitHub" @@ -231,7 +231,7 @@ impl ScanCommandArgs { None } } - ScanInputCommand::Gitlab(mut args) => { + ScanInputCommand::Gitlab(args) => { if args.specifiers.is_empty() { bail!( "Specify at least one --user, --group, or use --all-groups when scanning GitLab" @@ -256,7 +256,7 @@ impl ScanCommandArgs { None } } - ScanInputCommand::Gitea(mut args) => { + ScanInputCommand::Gitea(args) => { if args.specifiers.is_empty() { bail!( "Specify at least one --user, --org, or use --all-orgs when scanning Gitea" @@ -280,7 +280,7 @@ impl ScanCommandArgs { None } } - ScanInputCommand::Bitbucket(mut args) => { + ScanInputCommand::Bitbucket(args) => { if args.specifiers.is_empty() { bail!( "Specify at least one --user, --workspace, --project, or use --all-workspaces when scanning Bitbucket" @@ -306,7 +306,7 @@ impl ScanCommandArgs { None } } - ScanInputCommand::Azure(mut args) => { + ScanInputCommand::Azure(args) => { if args.specifiers.is_empty() { bail!( "Specify at least one --organization, --project, or use --all-projects when scanning Azure DevOps" @@ -330,7 +330,7 @@ impl ScanCommandArgs { None } } - ScanInputCommand::Huggingface(mut args) => { + ScanInputCommand::Huggingface(args) => { if args.specifiers.is_empty() { bail!( "Specify at least one --user, --org, --model, --dataset, or --space when scanning Hugging Face"