From 716d26810f7fab611b58807ceb3aa5dd3880c0ff Mon Sep 17 00:00:00 2001 From: dpilafian Date: Tue, 19 Mar 2024 02:39:00 -0700 Subject: [PATCH] Release v1.7.0 --- .github/workflows/release-on-vtag.yaml | 2 +- .github/workflows/run-spec-on-push.yaml | 4 ++-- dist/w3c-html-validator.d.ts | 2 +- dist/w3c-html-validator.js | 11 +++++------ package.json | 18 +++++++++--------- 5 files changed, 18 insertions(+), 19 deletions(-) diff --git a/.github/workflows/release-on-vtag.yaml b/.github/workflows/release-on-vtag.yaml index faed059..b323781 100644 --- a/.github/workflows/release-on-vtag.yaml +++ b/.github/workflows/release-on-vtag.yaml @@ -8,7 +8,7 @@ jobs: name: Create Release runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 #see: https://github.com/actions/checkout/releases - uses: actions/create-release@v1 env: GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} diff --git a/.github/workflows/run-spec-on-push.yaml b/.github/workflows/run-spec-on-push.yaml index 463ef8d..7e80991 100644 --- a/.github/workflows/run-spec-on-push.yaml +++ b/.github/workflows/run-spec-on-push.yaml @@ -5,7 +5,7 @@ jobs: name: Run Specifications runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 #see: https://github.com/actions/checkout/releases + - uses: actions/setup-node@v4 #see: https://github.com/actions/setup-node/releases - run: npm install - run: npm test diff --git a/dist/w3c-html-validator.d.ts b/dist/w3c-html-validator.d.ts index 7fca5c3..23edf5f 100644 --- a/dist/w3c-html-validator.d.ts +++ b/dist/w3c-html-validator.d.ts @@ -1,4 +1,4 @@ -//! w3c-html-validator v1.6.4 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License +//! w3c-html-validator v1.7.0 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License export type ValidatorSettings = { html: string; diff --git a/dist/w3c-html-validator.js b/dist/w3c-html-validator.js index a0bbcc3..4b1fa81 100644 --- a/dist/w3c-html-validator.js +++ b/dist/w3c-html-validator.js @@ -1,4 +1,4 @@ -//! w3c-html-validator v1.6.4 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License +//! w3c-html-validator v1.7.0 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License import chalk from 'chalk'; import fs from 'fs'; @@ -6,7 +6,7 @@ import log from 'fancy-log'; import request from 'superagent'; import slash from 'slash'; const w3cHtmlValidator = { - version: '1.6.4', + version: '1.7.0', validate(options) { const defaults = { checkUrl: 'https://validator.w3.org/nu/', @@ -62,10 +62,9 @@ const w3cHtmlValidator = { display: json ? null : response.text, }); const handleError = (reason) => { - const response = reason.response; - const getMsg = () => [response.status, response.res.statusMessage, response.request.url]; - const message = response ? getMsg() : [reason.errno, reason.message]; - const errRes = response ?? {}; + const errRes = reason.response ?? {}; + const getMsg = () => [errRes.status, errRes.res.statusMessage, errRes.request.url]; + const message = reason.response ? getMsg() : [reason.errno, reason.message]; errRes.body = { messages: [{ type: 'network-error', message: message.join(' ') }] }; return toValidatorResults(errRes); }; diff --git a/package.json b/package.json index 9536d21..018abef 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "w3c-html-validator", - "version": "1.6.4", + "version": "1.7.0", "description": "Check the markup validity of HTML files using the W3C validator", "license": "MIT", "type": "module", @@ -87,18 +87,18 @@ "@types/fancy-log": "~2.0", "@types/node": "~20.11", "@types/superagent": "~8.1", - "@typescript-eslint/eslint-plugin": "~6.19", - "@typescript-eslint/parser": "~6.19", - "add-dist-header": "~1.3", - "assert-deep-strict-equal": "~1.1", - "copy-file-util": "~1.1", + "@typescript-eslint/eslint-plugin": "~7.3", + "@typescript-eslint/parser": "~7.3", + "add-dist-header": "~1.4", + "assert-deep-strict-equal": "~1.2", + "copy-file-util": "~1.2", "copy-folder-util": "~1.1", - "eslint": "~8.56", + "eslint": "~8.57", "jshint": "~2.13", "merge-stream": "~2.0", - "mocha": "~10.2", + "mocha": "~10.3", "rimraf": "~5.0", "run-scripts-util": "~1.2", - "typescript": "~5.3" + "typescript": "~5.4" } }