Просмотр исходного кода

Fix SVGO zero percent filtering in CI (#9422)

Because of the environment variable `CI=true` being passed in GitHub Actions to SVGO, it outputted colored text with ANSI escape sequences, which broke the awk 0% filtering (for unchanged files).

Ref: https://github.com/FreshRSS/FreshRSS/pull/9361#discussion_r4147827482
Inverle 2 дней назад
Родитель
Сommit
07617c48e6
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      package.json

+ 1 - 1
package.json

@@ -28,7 +28,7 @@
 		"markdownlint": "markdownlint-cli2",
 		"markdownlint": "markdownlint-cli2",
 		"markdownlint_fix": "markdownlint-cli2 --fix",
 		"markdownlint_fix": "markdownlint-cli2 --fix",
 		"rtlcss": "rtlcss -d p/themes/ && find p/themes/ -type f -name '*.rtl.rtl.css' -delete",
 		"rtlcss": "rtlcss -d p/themes/ && find p/themes/ -type f -name '*.rtl.rtl.css' -delete",
-		"svgo": "find p/ docs/ -name '*.svg' -exec svgo {} + | awk '/:$/{name=$0;next} /KiB/ && !/ - 0% /{print name; print}'",
+		"svgo": "find p/ docs/ -name '*.svg' -exec svgo --no-color {} + | awk '/:$/{name=$0;next} /KiB/ && !/ - 0% /{print name; print}'",
 		"stylelint": "stylelint '**/*.css'",
 		"stylelint": "stylelint '**/*.css'",
 		"stylelint_fix": "stylelint --fix '**/*.css'",
 		"stylelint_fix": "stylelint --fix '**/*.css'",
 		"test": "npm run eslint && npm run stylelint && npm run markdownlint",
 		"test": "npm run eslint && npm run stylelint && npm run markdownlint",