I created this package to handle environment variables for many projects that I worked at. Since env variables values shouldn't be kept in repo the need for other storage is big. You can store env vars in seperate file that is listed in .gitignore, but experience teaches us, that this approach can fail and sensitive data can end up in the repo.
Linux users that uses amd64 architecture can download latest version from releases page
If you have go installed you can always go get
it
go get -u github.com/rkorkosz/kv
- To parse existing env file to kv database:
$ kv parse <filename>
- To list all stored variables:
$ kv ls
- To export all variables in shell:
$ export $(kv ls)
- To store one variable:
$ kv set KEY=VAL
or
$ kv set KEY VAL
kv
database by default is stored in $HOME/.kv/kv.db
.
As of now single storage implementation is based on bbolt
Suggestions and feature request are welcome :)