From ab3feda00773ff5387962236fca57cda44094526 Mon Sep 17 00:00:00 2001 From: Steve Yegge Date: Sat, 27 Dec 2025 22:24:14 -0800 Subject: [PATCH] fix: remove arbitrary 8-char prefix limit from rename-prefix (GH#770) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The limit wasn't enforced by init/create, so users could create issues with longer prefixes but couldn't use rename-prefix to consolidate them. Since the DB handles longer prefixes fine, just remove the limit. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- cmd/bd/rename_prefix.go | 4 ---- cmd/bd/rename_prefix_test.go | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/cmd/bd/rename_prefix.go b/cmd/bd/rename_prefix.go index f3c95c05..90dd20ce 100644 --- a/cmd/bd/rename_prefix.go +++ b/cmd/bd/rename_prefix.go @@ -188,10 +188,6 @@ func validatePrefix(prefix string) error { return fmt.Errorf("prefix cannot be empty") } - if len(prefix) > 8 { - return fmt.Errorf("prefix too long (max 8 characters): %s", prefix) - } - matched, _ := regexp.MatchString(`^[a-z][a-z0-9-]*$`, prefix) if !matched { return fmt.Errorf("prefix must start with a lowercase letter and contain only lowercase letters, numbers, and hyphens: %s", prefix) diff --git a/cmd/bd/rename_prefix_test.go b/cmd/bd/rename_prefix_test.go index b44417db..d3fb14b1 100644 --- a/cmd/bd/rename_prefix_test.go +++ b/cmd/bd/rename_prefix_test.go @@ -20,7 +20,7 @@ func TestValidatePrefix(t *testing.T) { {"valid with numbers", "work1-", false}, {"valid with hyphen", "my-work-", false}, {"empty", "", true}, - {"too long", "verylongprefix-", true}, + {"long prefix ok", "verylongprefix-", false}, // No length limit (GH#770) {"starts with number", "1work-", true}, {"uppercase", "KW-", true}, {"no hyphen", "kw", false},