From 8b9e2c17cc0210b43e5bde6b7eec3e8113524fb5 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Thu, 8 Dec 2016 23:13:19 -0500 Subject: [PATCH] config: fix NameRegexp validation to allow single-char names --- config/config.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/config.go b/config/config.go index eb2adb8ab2..da39051c19 100644 --- a/config/config.go +++ b/config/config.go @@ -18,7 +18,7 @@ import ( // NameRegexp is the regular expression that all names (modules, providers, // resources, etc.) must follow. -var NameRegexp = regexp.MustCompile(`(?i)\A[A-Z_][A-Z0-9\-\_]+\z`) +var NameRegexp = regexp.MustCompile(`(?i)\A[A-Z_][A-Z0-9\-\_]*\z`) // Config is the configuration that comes from loading a collection // of Terraform templates.