kv - a simple flat file key value store.
kv [OPTION]... [FILE]...
kv provides an interface for storing, retrieving and deleting key-value pairs stored in json encoded flat files. Its usage is aimed towards shell scripts and command line driven environments.
delete a key in the database
specify a format string; %k and %v are placeholders for key and value respectively
displays a short-help text and exits
list couples of key and values
display value of this key or update the key if --value is specified
update or set a key in the database
displays the program version, copyright and license information and exists.
Record a new key-value pair.
$ kv -k kv_location -v /home/user/.local/bin/ /home/user/.cache/kv.db
Get the value of a record
$ kv -k kv_location /home/user/.cache/kv.db
List all records and print them with a custom format
$ kv -l -f "%k -- %v" /home/user/.cache/kv.db
Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later (http://gnu.org/licenses/gpl.html). This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
Written by Francesco Mecca ([email protected]).