Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
uses: actions/checkout@v5

# Node 17+ dropped PostCSS 8.1's "./" exports fallback, which broke
# gulp-stylelint 13 / postcss-syntax. CSS lint now uses stylelint 14.
- name: Set up Node.js
uses: actions/setup-node@v4
uses: actions/setup-node@v5
with:
node-version: 20
node-version-file: .nvmrc
cache: npm

- name: Install dependencies
Expand All @@ -44,7 +46,7 @@ jobs:
run: npx gulp bundle

- name: Upload bundle artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: ui-bundle
path: build/ui-bundle.zip
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10
20
14 changes: 14 additions & 0 deletions .stylelintrc
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,19 @@
"rules": {
"comment-empty-line-before": null,
"no-descending-specificity": null,
"value-keyword-case": ["lower", { "ignoreKeywords": ["Arial", "currentColor"] }],
"custom-property-pattern": null,
"selector-class-pattern": null,
"keyframes-name-pattern": null,
"function-url-quotes": null,
"font-family-name-quotes": null,
"string-quotes": null,
"color-function-notation": null,
"alpha-value-notation": null,
"value-no-vendor-prefix": null,
"property-no-vendor-prefix": null,
"selector-attribute-quotes": null,
"shorthand-property-no-redundant-values": null,
"max-line-length": null
}
}
17 changes: 10 additions & 7 deletions gulp.d/tasks/lint-css.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
'use strict'

const stylelint = require('gulp-stylelint')
const vfs = require('vinyl-fs')
const stylelint = require('stylelint')

module.exports = (files) => (done) =>
vfs
.src(files)
.pipe(stylelint({ reporters: [{ formatter: 'string', console: true }], failAfterError: true }))
.on('error', done)
module.exports = (files) => () =>
stylelint.lint({ files, formatter: 'string' }).then((result) => {
if (result.output) process.stdout.write(result.output)
if (result.errored) {
const error = new Error('Failed with stylelint errors')
error.showStack = false
throw error
}
})
Loading