* Output every file reset
* Add --dry-run and --reason options to reset-translated-file.js
* Output reason when reset-translated-file.js script is called
* Fix error
* Attempt to fix that error
* Remove debugging code
* fix: Update path of lint-translation script
* fix: Update conditional guard clause
The conditional compared an array to a string using strict equality, so
it was never going to be true. This change makes sure we return early
when there are no changes.
* fix: Exit early when there are no files to lint
* refactor: Filter files to reset in plain javascript
As opposed to doing it in bash.
* Update tests/linting/lint-files.js
Co-authored-by: Francis <15894826+francisfuzz@users.noreply.github.com>
* Update tests/linting/lint-files.js
Co-authored-by: Francis <15894826+francisfuzz@users.noreply.github.com>
* Update script/i18n/lint-translation-files.js
Co-authored-by: Francis <15894826+francisfuzz@users.noreply.github.com>
Co-authored-by: Francis <15894826+francisfuzz@users.noreply.github.com>
* fix: update lint-translation script to point to the correct test
This change reflects its new home in `test/linting/lint-files.js` as committed in f0d17c300d on April 28, 2021.
* test: check release notes can be parsed a single YAML document
* test: check yaml content parsability
* test: check parsability for all YAML content
* refactor: move annotations to lint yaml content suite
* fix: revert file contents
* fix: remove local test script
* refactor: lowercase yaml file type
* fix: remove null assignment to stay consistent with other variables
* refactor: update reference name to caught error
* fix: remove the royal we from annotation
* refactor: update annotation for improved readability
* fix: add missing preposition
* fix: make script for linting translations executable
* fix: execute the command directly
* feat: surface any errors if lint check fails
* fix: do not return early if lint check errors
Co-authored-by: Octomerger Bot <63058869+Octomerger@users.noreply.github.com>
* feat: stub two reset scripts
* refactor: split lint script into two separate files
* fix: revert back to original lint script
* refactor: use commander interface for linting translation files
* Skip reset attempt when violation list is empty
So that "execSync(`cat ${log}...`)" in line 64 is never executed. When
there are no errors, the log file is not created, and unless it had been
previously created by another process, the script will error out.
Co-authored-by: Marcelo Jacobus <marcelo.jacobus@gmail.com>