discover-rewards-notifier
discover-rewards-notifier copied to clipboard
Fail CircleCI builds when files have syntax errors
Fail a CircleCI build when a file has a syntax error. We should check all of the following file types:
- .js
- .json
- .html
- .css
The most important files to check would be in the /src/
directory. These are the code for the Chrome Extension, and we won't know that it's failing if we were to deploy it to users.
If I'm not wrong this could be fixed adding a -run command and check that all files provided have the required extension. If I'm right i can easily modify the config.yml file in order to check the files extension.
Hey! Yes, we could check the file extension but that won't tell us if there's a syntax error in the actual file.
For example, json
file could be formatted because a contributor accidentally deleted a comma. The circleci build will still pass, but the extension would fail at run-time due to the incorrect JSON.
Based on the file extension, we need some way of checking if the syntax is correct for that file. Does that make sense?