fix(cli): allow template name length of 32 in template push and create (#11915)

This commit is contained in:
Mathias Fredriksson
2024-01-30 12:47:10 +02:00
committed by GitHub
parent 86e33257af
commit 60653bbacb
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -79,8 +79,8 @@ func (r *RootCmd) templateCreate() *clibase.Cmd {
return err
}
if utf8.RuneCountInString(templateName) > 31 {
return xerrors.Errorf("Template name must be less than 32 characters")
if utf8.RuneCountInString(templateName) > 32 {
return xerrors.Errorf("Template name must be no more than 32 characters")
}
_, err = client.TemplateByName(inv.Context(), organization.ID, templateName)
+2 -2
View File
@@ -56,8 +56,8 @@ func (r *RootCmd) templatePush() *clibase.Cmd {
return err
}
if utf8.RuneCountInString(name) >= 32 {
return xerrors.Errorf("Template name must be less than 32 characters")
if utf8.RuneCountInString(name) > 32 {
return xerrors.Errorf("Template name must be no more than 32 characters")
}
var createTemplate bool