You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add Makefileformat target rules to reformat *.json and *.jsonc files.
Add Makefilecheck target rules to check the format of json files.
Add pre-commit config hooks using either prettier or pretty-format-json
Require those rules and reformat json files.
Rename *.jsonc files to *.mlos.jsonc files.
Might as well do this at the same time we're rewriting all files.
See Also: external config improvements #522
The text was updated successfully, but these errors were encountered:
I played with this a little bit in #930, but all the tools I've found so far currently strip the comments from the jsonc files which I don't think we want.
bpkroth
changed the title
prettier formatting for json files
automatic formatting for json files
Jan 17, 2025
# Pull Request
## Title
Json Checking
______________________________________________________________________
## Description
Add pre-commit hooks to check ~and format~ json/json5.
- [x] remove prettier config
- [x] check json5 files
- [ ] ~preserve comments when formatting~
- [ ] ~rename mlos_bench config files to `*.mlos.jsonc`~
______________________________________________________________________
## Type of Change
- ✨ New feature
______________________________________________________________________
## Additional Comments
See #882 for comments regarding the difficulty in auto-formatting
jsonc/json5 while also preserving comments.
We leave this for future work.
______________________________________________________________________
AddMakefile
format
target rules to reformat*.json
and*.jsonc
files.AddMakefile
check
target rules to check the format of json files.pre-commit
config hooks using eitherprettier
orpretty-format-json
*.jsonc
files to*.mlos.jsonc
files.Might as well do this at the same time we're rewriting all files.
See Also: external config improvements #522
The text was updated successfully, but these errors were encountered: