zkapp-cli
zkapp-cli copied to clipboard
Add `check` command
To check the project against current conventions and best practices. Why current and not "current for the version of SnarkyJS used"...to encourage consistency in the ecosystem.
Codify the current conventions and automatically check the current dir for:
- [ ] expected dir structure & files
- [ ]
.prettierrcexists & follows current format (and code passes?) - [ ] lint config file exists & follows current rules (and code passes?)
- [ ]
package-lock.jsonexists in Git (b/c it's required by thenpm cicommand used in CI templates) - [ ] tests exist (and pass?)
- [ ] test coverage above x%? or function call coverage at 100%?
Could add a CI file for this too. Write this in JS and it can be used by both the CLI & CI workflow.
For failures, we might want to give a link to a conventions.md (to the proper section header within it) which explains 1.) the expected convention, and 2.) why.
- [ ] Add
--fixor as a separate command to automatically update the user's project to current recommendations for Prettier/Eslint/etc configs, ignore files, etc.
To discuss. We may not take this approach
Closing to clean up. Not realistic that we prioritize this anytime soon. Need for it hasn't been seen in practice yet