Commit graph

5 commits

Author SHA1 Message Date
James Nugent 94aed0717f cli: Fix panic on empty data argument to kv put
Passing in an empty quoted argument from the shell currently panics as
we never check the length being greater than 0 prior to indexing into
the first rune, as illustrated in the test in this commit.

We also fix the panic, treating an empty string for data as equivalent
to not having passed it in the first place.
2017-01-05 08:02:38 -06:00
James Nugent c32fe92eee cli: Add -base64 option to consul kv put
This commit adds a -base64 option to the consul kv put command, which
base 64 decodeds the data prior to writing it. This can be used in
conjunction with `consul kv get -base64 key`.
2017-01-04 16:12:21 -06:00
mckennajones a99f840653 Unit test for kv_put with negative values 2016-11-29 22:29:31 -08:00
Seth Vargo 70fd7efde9
Fix CAS operations for put 2016-09-26 16:06:56 -07:00
Seth Vargo d5dd8ef7a1
Add kv put command 2016-09-26 16:06:53 -07:00