Skip to content

Commit

Permalink
[CI] Only report registry format errors by default (open-telemetry#4940)
Browse files Browse the repository at this point in the history
  • Loading branch information
chalin authored Aug 2, 2024
1 parent 519f8f2 commit 6a828d6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion gulp-src/validate-registry.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const defaultGlobs = ['data/registry/*.yml'];

let numFilesProcessed = 0,
numFilesWithIssues = 0;
let debugFlag = false;

const schema = require('../data/registry-schema.json');
const ajv = new Ajv({
Expand Down Expand Up @@ -125,7 +126,7 @@ function validateRegistryEntry(file, enc, cb) {
console.log(
`::${logLevel} file=${file.path},line=${lineNumber},endLine=${lineNumber},title=Registry Schema Validation::${error.message}`,
);
} else {
} else if (debugFlag) {
console.log(error);
console.error(
`${logLevel} in ${file.path}:${lineNumber}: ${error.message}`,
Expand Down Expand Up @@ -165,6 +166,7 @@ function validateRegistry() {
if (argv.debug) {
console.log('Globs being used:', globs);
}
debugFlag = argv.debug;

return gulp
.src(globs, { followSymlinks: false })
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"check:links:internal": "npm run _check:links:internal",
"check:links": "npm run _check:links",
"check:markdown": "scripts/check-markdown-wrapper.sh",
"check:registry": "npm run _check:registry",
"check:registry": "npm run _check:registry -- ",
"check:spelling": "npx cspell --no-progress -c .cspell.yml content/en data 'layouts/**/*.md'",
"check:text": "npm run _check:text -- ",
"check": "npm run seq -- $(npm run -s _list:check:*)",
Expand Down

0 comments on commit 6a828d6

Please sign in to comment.