From a41b94658a587e98fbeb2ed2923301b5cf1a9b01 Mon Sep 17 00:00:00 2001 From: KeisukeYamashita <19yamashita15@gmail.com> Date: Tue, 2 Nov 2021 22:33:48 +0900 Subject: [PATCH] Add validate func for repository name Signed-off-by: KeisukeYamashita <19yamashita15@gmail.com> --- github/resource_github_repository.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/github/resource_github_repository.go b/github/resource_github_repository.go index 8adf0be130..8737dc15af 100644 --- a/github/resource_github_repository.go +++ b/github/resource_github_repository.go @@ -29,8 +29,9 @@ func resourceGithubRepository() *schema.Resource { Schema: map[string]*schema.Schema{ "name": { - Type: schema.TypeString, - Required: true, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringLenBetween(1, 100), }, "description": { Type: schema.TypeString,