Skip to content

Commit

Permalink
Update svglint to 3.1.0
Browse files Browse the repository at this point in the history
The new release contains:
 - simple-icons/svglint#110
 - simple-icons/svglint#111

which allow us to slightly simplify our code.
  • Loading branch information
calixteman committed Nov 18, 2024
1 parent 3219d49 commit 1c5d93c
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 12 deletions.
14 changes: 14 additions & 0 deletions .svglintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,18 @@ export default {
},
],
},
ignore: [
"build/**",
"l10n/**",
"docs/**",
"node_modules/**",
"external/bcmaps/**",
"external/builder/fixtures/**",
"external/builder/fixtures_babel/**",
"external/quickjs/**",
"test/tmp/**",
"test/pdfs/**",
"web/locale/**",
"*~/**",
],
};
10 changes: 3 additions & 7 deletions gulpfile.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -1983,8 +1983,9 @@ gulp.task("lint", function (done) {

const svgLintOptions = [
"node_modules/svglint/bin/cli.js",
"web/**/*.svg",
"**/*.svg",
"--ci",
"--no-summary",
];

const esLintProcess = startNode(esLintOptions, { stdio: "inherit" });
Expand All @@ -2009,12 +2010,7 @@ gulp.task("lint", function (done) {
}

const svgLintProcess = startNode(svgLintOptions, {
stdio: "pipe",
});
svgLintProcess.stdout.setEncoding("utf8");
svgLintProcess.stdout.on("data", m => {
m = m.toString().replace(/-+ Summary -+.*/ms, "");
console.log(m);
stdio: "inherit",
});
svgLintProcess.on("close", function (svgLintCode) {
if (svgLintCode !== 0) {
Expand Down
9 changes: 5 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"puppeteer": "23.3.1",
"stylelint": "^16.10.0",
"stylelint-prettier": "^5.0.2",
"svglint": "^3.0.0",
"svglint": "^3.1.0",
"terser-webpack-plugin": "^5.3.10",
"tsc-alias": "^1.8.10",
"ttest": "^4.0.0",
Expand Down

0 comments on commit 1c5d93c

Please sign in to comment.