From cf9ce7b4755c4654b904ea3964030ab17bc7d374 Mon Sep 17 00:00:00 2001 From: Mihai Chitic Date: Tue, 19 May 2026 15:27:19 +0300 Subject: [PATCH 1/2] [ND-7669] - accept new PAT format --- cmd/configure/profile/add.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cmd/configure/profile/add.go b/cmd/configure/profile/add.go index bfed0f1..9ce96ce 100644 --- a/cmd/configure/profile/add.go +++ b/cmd/configure/profile/add.go @@ -17,7 +17,8 @@ import ( ) var ( - tokenFormat = regexp.MustCompile(`^\d+:[0-9a-zA-z]{32}$`) + legacyTokenFormat = regexp.MustCompile(`^\d+:[0-9a-zA-Z]{32}$`) + patTokenFormat = regexp.MustCompile(`^bns_pat_[A-Za-z0-9]{32,}$`) ErrInvalidToken = errors.New("invalid token") ) @@ -257,7 +258,7 @@ func validateToken(input interface{}) error { return interactive.ErrInvalidValue } - if !tokenFormat.Match([]byte(value)) { + if !legacyTokenFormat.MatchString(value) && !patTokenFormat.MatchString(value) { return fmt.Errorf("%w: token is invalid", interactive.ErrInvalidValue) } From ac498276a6c7f98d08e321a9b4c4b5fad265e8bb Mon Sep 17 00:00:00 2001 From: Mihai Chitic Date: Tue, 19 May 2026 15:40:37 +0300 Subject: [PATCH 2/2] [ND-7649] - fix pipeline logs flags naming, from camelCase to kebab-case --- cmd/pipeline/logs.go | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/cmd/pipeline/logs.go b/cmd/pipeline/logs.go index 2877a30..8be76b1 100644 --- a/cmd/pipeline/logs.go +++ b/cmd/pipeline/logs.go @@ -101,8 +101,16 @@ func init() { }, ", ") flags.StringArrayVar(&jobs, "job", jobs, "Filter to specific job ID(s) (repeatable)") - flags.StringArrayVar(&jobStatuses, "jobStatus", jobStatuses, fmt.Sprintf("Filter by job status (repeatable); possible values: %s", jobStatusValues)) - flags.StringArrayVar(&stepStatuses, "stepStatus", stepStatuses, fmt.Sprintf("Filter by step status (repeatable); possible values: %s", stepStatusValues)) + flags.StringArrayVar(&jobStatuses, "job-status", jobStatuses, fmt.Sprintf("Filter by job status (repeatable); possible values: %s", jobStatusValues)) + flags.StringArrayVar(&stepStatuses, "step-status", stepStatuses, fmt.Sprintf("Filter by step status (repeatable); possible values: %s", stepStatusValues)) + + // Backward-compatible aliases for existing automation scripts. + flags.StringArrayVar(&jobStatuses, "jobStatus", jobStatuses, "") + flags.StringArrayVar(&stepStatuses, "stepStatus", stepStatuses, "") + _ = flags.MarkHidden("jobStatus") + _ = flags.MarkHidden("stepStatus") + _ = flags.MarkDeprecated("jobStatus", "use --job-status") + _ = flags.MarkDeprecated("stepStatus", "use --step-status") mainCmd.AddCommand(command) }