This PR implements the --keep-existing feature, mentioned in #14 . As I stated there, this is implemented by maintaining the current state in a file named cherryrgb_state.json in the directory, determined by dirs::cache_dir(). To showcase the functionality, several example profiles have been added as well.
While working on the new examples, I also felt the desire to have comments in the profile. Therefore, the following was implemented:
Relax parsing of key profiles:
Allow comments using //
Allow trailing comma after last element
Fixes #14
Type of change
Please delete options that are not relevant.
[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] Adds/updates Documentation
Code Checklist
[x] I have performed a self-review of my own code
[ ] I have made corresponding changes to the documentation (not yet - will be a separate PR including docs, generated by xtask)
[x] My changes generate no new warnings
[x] I have implemented respective test(s)
[x] I have run lints and tests (cargo fmt && cargo clippy && cargo test) that prove my fix is effective or that my feature works
This PR implements the
--keep-existing
feature, mentioned in #14 . As I stated there, this is implemented by maintaining the current state in a file namedcherryrgb_state.json
in the directory, determined by dirs::cache_dir(). To showcase the functionality, several example profiles have been added as well. While working on the new examples, I also felt the desire to have comments in the profile. Therefore, the following was implemented://
Fixes #14
Type of change
Please delete options that are not relevant.
Code Checklist