Skip to content
This repository was archived by the owner on Feb 16, 2023. It is now read-only.

Commit d32f9e4

Browse files
committed
Improve composite secret error message
1 parent 5db27d0 commit d32f9e4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

internals/secrethub/migrate_config_envfile.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,11 @@ func (cmd *MigrateConfigEnvfileCommand) Run() error {
5555
return nil
5656
}
5757

58-
var regexpCompositeSecrets = regexp.MustCompile(`{{.+?}}[^\s]`)
58+
var regexpCompositeSecrets = regexp.MustCompile(`{{.+?}}[^\s]+`)
5959

6060
func checkForCompositeSecrets(inFileContents []byte) error {
6161
if match := regexpCompositeSecrets.Find(inFileContents); match != nil {
62-
return fmt.Errorf("composite environment variables are not supported anymore with Dotenv: %s\nMake sure one environment variable corresponds to a single secret.", match)
62+
return fmt.Errorf("composite environment variables are not supported anymore with Dotenv: %s\nMake sure one environment variable corresponds to just a single secret", match)
6363
}
6464
return nil
6565
}

0 commit comments

Comments
 (0)