Closed inzanity closed 5 years ago
The problem with long prefixes in C is that they are repeated. Everywhere. I'm not against s///g'in it entirely, but to me it makes sense to keep it short. Granted the function names etc are already long, and the added length doesn't add much, but IMO things are more readable when the common prefix is shorter.
I would consider shortening sf_secrets_
prefix to just sfs_
:)
e.g.
sfs_collection_get_encryption_plugin_name
sf_secrets_collection_get_encryption_plugin_name
sailfish_secrets_collection_get_encryption_plugin_name
I was thinking that too, not just for shortness, but also because then the TYPE in macro names would sit nicely in more logical position. :)
The Crypto API is looking good, really nice work. Obviously a few more things to go (e.g. changing the secrets API a bit, supporting (symmetric) key derivation and (asymmetric) key generation parameters in the crypto API, and unit tests for everything, but definitely looking great!
What's the motivation behind variant to bool change in the dbus interface? Pondering who much we'll break with this?
That being said once commits are cleaned up we should get this integrated.
Usually we use 4spaces per indentation level, now there are tabs. Could you replace those.
Usually we use 4spaces per indentation level, now there are tabs. Could you replace those.
Let me leave my 2¢ here. I don't like tabs at all and generally try to avoid them but at the same time I don't feel good about forcing people to use spaces for indentation. As long as it's consistent within the component (i.e. tabs are not mixed with spaces) I would leave it the way it is in the form which is most comfortable to the person who is most likely going to maintain this code. Programming is a lot more fun if you like the code that you're writing which (hopefully) translates into quality. And the opposite doesn't translate into quality, that's for sure :)
What happened to cause all of the conflicts here?
@chriadam see https://github.com/sailfishos/sailfish-secrets/pull/151 . @inzanity prepared a cleanup commit set.
This should be closed as well.
Obsoleted by #151
Purely cosmetic, but I don't know if we use short-form naming (like sf) anywhere, possibly "sailfish" could be more consistent even though more verbose.