Shitty key-value store in C inspired by Redis.
$ make $ bin/shitdb [port]
$ nc localhost 4999 SET foo "bar" OK GET foo "bar" SET bar 123 OK GET bar 123 QUIT Bye!
- Integer: 2834
- String: "yuhuuuu"
- Array: [42,"foo",9999]
- Hashes: (no literal representation)
- GET [key]: Returns the content of a key.
- SET [key] [value]: Sets key to a value of any of the basic types.
- DELETE [key]: Deletes a key.
- CLEAR: Clears all keys.
- QUIT: Ends the connection.
- APUSH [key] [value]: Pushes value to the array located at key.
- APOP [key]: Pops the array located at key and returns the popped value.
- AAT [key] [index]: Gets the array element at a certain index.
- ACOUNT [key]: Returns the number of elements in the array.
- HSET [key] [hashkey] [value]: Sets the hashkey in the Hash object in key to a value.
- HGET [key] [hashkey]: Gets the value of the hashkey in the Hash object in key.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Added some feature')
- Push to the branch (
git push origin my-new-feature)
- Create new Pull Request