Skip to content
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

Add a Warning to Generated .json Files: DO NOT EDIT MANUALLY #7

Open
SableRaf opened this issue Jul 12, 2024 · 0 comments
Open

Add a Warning to Generated .json Files: DO NOT EDIT MANUALLY #7

SableRaf opened this issue Jul 12, 2024 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@SableRaf
Copy link
Contributor

SableRaf commented Jul 12, 2024

Rationale

Contributors are frequently submitting PRs to the processing-website repository with manual edits to auto-generated .json files. This leads to confusion and unnecessary work. See for example: processing/processing-website#471 and processing/processing-website#524.

Proposed solution

To prevent confusion and incorrect manual edits to auto-generated .json files, prepend a prominent warning to the generated .json files. The warning should explain that the files should not be edited manually and provide a link to the documentation. Optionally it could also link to the file containing the corresponding JavaDoc annotation.

A possible message would be:

// WARNING: This file is auto-generated. DO NOT EDIT MANUALLY.
// Changes to this documentation should be made in the corresponding JavaDoc annotations.
// For more information, refer to the Doclet script documentation: https://github.com/processing/processing-doclet/blob/main/README.md
// The source for this file is located at [link to corresponding file]

Edit: I realize the JSON standard doesn't allow comments but we could strip the comments before feeding the files to the parser if it causes issues.

References

@SableRaf SableRaf added the enhancement New feature or request label Jul 12, 2024
@SableRaf SableRaf changed the title Add a Detailed Warning to Generated JSON Files: DO NOT EDIT MANUALLY Add a Detailed Warning to Generated .json Files: DO NOT EDIT MANUALLY Jul 12, 2024
@SableRaf SableRaf changed the title Add a Detailed Warning to Generated .json Files: DO NOT EDIT MANUALLY Add a Warning to Generated .json Files: DO NOT EDIT MANUALLY Jul 12, 2024
@SableRaf SableRaf added the help wanted Extra attention is needed label Jul 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant