ghost
ghost copied to clipboard
Allow to version keys
Currently, a key will be overridden if a put --modify command was executed on it. Allowing to create a new version of the key, which will become the default key will allow users to look back at previous versions of the key. This might prevent situations in which users unknowingly overrode keys they still need.
Versioning should be the default, but we can also allow the user to override.
As of now, the identifier for the version should be the key's name, which means that multiple keys with the same name but a different version will be possible.
If a user creates a key and the key's name wasn't found, it should give it a version of 1 If a key with the same name was found, the new key should get a version 2 and so on. Retrieving a key should always get the latest version of it.