From c2b5cd63c3751b6128ddc1717e84d495cbb239bd Mon Sep 17 00:00:00 2001 From: nokko <13428215+nok-ko@users.noreply.github.com> Date: Sat, 7 May 2022 00:34:32 -0700 Subject: [PATCH 1/5] Add CSS Validation Workflow. --- .github/workflows/validate-css-html.yml | 9 +++++++++ .stylelintrc | 8 ++++++++ 2 files changed, 17 insertions(+) create mode 100644 .stylelintrc diff --git a/.github/workflows/validate-css-html.yml b/.github/workflows/validate-css-html.yml index d552dc6..bc8bc33 100644 --- a/.github/workflows/validate-css-html.yml +++ b/.github/workflows/validate-css-html.yml @@ -5,6 +5,15 @@ on: # Example from https://github.com/Cyb3r-Jak3/html5validator-action/wiki/Getting-Started jobs: + linters: + name: stylelint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - uses: actions-hub/stylelint@master + env: + PATTERN: "*.css" + INDENT_SPACES: 4 build: runs-on: ubuntu-latest steps: diff --git a/.stylelintrc b/.stylelintrc new file mode 100644 index 0000000..0351abf --- /dev/null +++ b/.stylelintrc @@ -0,0 +1,8 @@ +{ + "plugins": [ + "stylelint-csstree-validator" + ], + "rules": { + "csstree/validator": true + } +} \ No newline at end of file From ca1beaacada3b14e2dba68d95f52b78054e4b980 Mon Sep 17 00:00:00 2001 From: nokko <13428215+nok-ko@users.noreply.github.com> Date: Sat, 7 May 2022 00:36:12 -0700 Subject: [PATCH 2/5] Update PATTERN in stylelint config --- .github/workflows/validate-css-html.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/validate-css-html.yml b/.github/workflows/validate-css-html.yml index bc8bc33..56664e3 100644 --- a/.github/workflows/validate-css-html.yml +++ b/.github/workflows/validate-css-html.yml @@ -12,7 +12,7 @@ jobs: - uses: actions/checkout@v1 - uses: actions-hub/stylelint@master env: - PATTERN: "*.css" + PATTERN: "public/css/*.css" INDENT_SPACES: 4 build: runs-on: ubuntu-latest From 7feb9fe7a49f2af650b82048e4025e6739132cc7 Mon Sep 17 00:00:00 2001 From: nokko <13428215+nok-ko@users.noreply.github.com> Date: Sat, 7 May 2022 00:42:16 -0700 Subject: [PATCH 3/5] =?UTF-8?q?Use=20custom=20CSS=20Validator=20action?= =?UTF-8?q?=E2=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/validate-css-html.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/validate-css-html.yml b/.github/workflows/validate-css-html.yml index 56664e3..f6b89b5 100644 --- a/.github/workflows/validate-css-html.yml +++ b/.github/workflows/validate-css-html.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v1 - - uses: actions-hub/stylelint@master + - uses: nok-ko/stylelint-csstree-validator-action@nok-ko-patch-csstree env: PATTERN: "public/css/*.css" INDENT_SPACES: 4 From 93e459f4665b322e4075914e3432d2d92e2365f6 Mon Sep 17 00:00:00 2001 From: Katy Petrova <13428215+nok-ko@users.noreply.github.com> Date: Sat, 7 May 2022 01:17:33 -0700 Subject: [PATCH 4/5] =?UTF-8?q?Use=20Katy's=20custom=20GH=20Action=20and?= =?UTF-8?q?=20hope=20it=20works=E2=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/validate-css-html.yml | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/.github/workflows/validate-css-html.yml b/.github/workflows/validate-css-html.yml index f6b89b5..373b3fb 100644 --- a/.github/workflows/validate-css-html.yml +++ b/.github/workflows/validate-css-html.yml @@ -5,20 +5,15 @@ on: # Example from https://github.com/Cyb3r-Jak3/html5validator-action/wiki/Getting-Started jobs: - linters: - name: stylelint - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 - - uses: nok-ko/stylelint-csstree-validator-action@nok-ko-patch-csstree - env: - PATTERN: "public/css/*.css" - INDENT_SPACES: 4 build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 # Requried with all actions + - uses: actions/checkout@v2 # Required with all actions - name: Checks HTML5 uses: Cyb3r-Jak3/html5validator-action@v7.1.1 with: root: html/ + - name: Validates CSS + uses: nok-ko/validate-css-action@main + with: + directory: public/css From b5fdd4088467381a1379b925e4a850312ff66921 Mon Sep 17 00:00:00 2001 From: Katy Petrova <13428215+nok-ko@users.noreply.github.com> Date: Mon, 9 May 2022 13:52:29 -0700 Subject: [PATCH 5/5] Remove unused .stylelintrc file. --- .github/workflows/validate-css-html.yml | 4 ++-- .stylelintrc | 8 -------- 2 files changed, 2 insertions(+), 10 deletions(-) delete mode 100644 .stylelintrc diff --git a/.github/workflows/validate-css-html.yml b/.github/workflows/validate-css-html.yml index 373b3fb..5675f17 100644 --- a/.github/workflows/validate-css-html.yml +++ b/.github/workflows/validate-css-html.yml @@ -1,11 +1,11 @@ -name: HTML Check +name: HTML & CSS Check on: push: # Example from https://github.com/Cyb3r-Jak3/html5validator-action/wiki/Getting-Started jobs: - build: + html-css-check: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 # Required with all actions diff --git a/.stylelintrc b/.stylelintrc deleted file mode 100644 index 0351abf..0000000 --- a/.stylelintrc +++ /dev/null @@ -1,8 +0,0 @@ -{ - "plugins": [ - "stylelint-csstree-validator" - ], - "rules": { - "csstree/validator": true - } -} \ No newline at end of file