heroku / heroku/cli

issues passing values with whitespace to config:set

Open
#1,520 1 comment 5 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
889
Forks
236
Avg merge
2d 10h
Merged PRs (30d)
33

Description

What is the current behavior?
-----------------------------
If typing manually into the shell, I can type something like:
`heroku config:set FOO=bar SPACE="Acme Corp" FIZZ=buzz`
This works correctly!

However if I have a file with KV pairs such as:
```
FOO=bar
SPACE="Acme Corp"
FIZZ=buzz
```

and run `heroku config:set $(cat )`, I get the error:
'Corp" is invalid. Must be in the format FOO=bar.'

How can I get these KV pair into the config:set command correctly? There's gotta be a way to properly pass the entries with spaces into this command that I'm missing

I also tried putting all the KV entries on one line separated by spaces. It really feels like this command should accept input from stdin so I can redirect the file in or something.

What is the expected behavior?
------------------------------
I would expect it to function the same as if you input the values manually, and to parse the entry as `SPACE="Acme Corp"`, instead it is parsing as `SPACE="Acme` and `Corp"` separately.

`heroku --version`
```
heroku/7.41.1 darwin-x64 node-v12.16.2
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.