-
-
Notifications
You must be signed in to change notification settings - Fork 462
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow Trailing Commas in repomix.config.json
#346
Comments
Or maybe we should support |
Hi, @rockmandash ! Yes, parsing with json5 sounds like a good solution for the trailing comma issue. Regarding the js/ts config file support - I've been considering this for a while but haven't implemented it yet due to complexity concerns. I know there's demand for it, so I'll keep it under consideration for future updates. |
- Replace JSON.parse with JSON5.parse for configuration file loading - Update tests to cover JSON5 features (comments, trailing commas) - Update documentation to reflect JSON5 support - Add json5 package as a dependency
- Replace JSON.parse with JSON5.parse for configuration file loading - Update tests to cover JSON5 features (comments, trailing commas) - Update documentation to reflect JSON5 support - Add json5 package as a dependency
When working with the
"includes"
key, I often comment out file paths to quickly test or calculate final token counts. However, I have to manually remove the trailing comma every time. Since comments are already supported inrepomix.config.json
, it would be very helpful if trailing commas were supported as well.For reference, you can see where this is handled in our code:
repomix/src/config/configLoad.ts
Line 70 in b55c59d
Additionally, the json5 library, which we could consider as an alternative, supports trailing commas.
The text was updated successfully, but these errors were encountered: