We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2ff02e0 commit c27cef3Copy full SHA for c27cef3
1 file changed
plugin.go
@@ -443,16 +443,16 @@ func parseEnv(raw interface{}) (map[string]string, error) {
443
444
result := make(map[string]string)
445
for _, v := range raw.([]interface{}) {
446
- split := strings.Split(v.(string), "=")
447
- key, value := strings.TrimSpace(split[0]), split[1:]
+ split := strings.SplitN(v.(string), "=", 2)
+ key := strings.TrimSpace(split[0])
448
449
// only key exists. set value from env
450
- if len(key) > 0 && len(value) == 0 {
+ if len(key) > 0 && len(split) == 1 {
451
result[key] = env(key, "")
452
}
453
454
- if len(value) > 0 {
455
- result[key] = strings.TrimSpace(value[0])
+ if len(split) == 2 {
+ result[key] = strings.TrimSpace(split[1])
456
457
458
0 commit comments