From 1096aac3d5ed98b03f9e8ba7d53f600099d3d487 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 1 Sep 2020 12:18:45 +0300 Subject: [PATCH 01/13] Added markdown links checker --- .github/workflows/ci.yml | 13 ++++++++++++- markdown.links.config.json | 10 ++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 markdown.links.config.json diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c77b7eb994fb..678aaea2d311 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -153,7 +153,7 @@ jobs: - run: sudo apt-get install xvfb - name: Run smoke tests run: xvfb-run --auto-servernum yarn smoke --debug -j=1 --retries=2 --invert-match ${{ matrix.smoke-test-invert }} $SMOKE_GROUP_1 - + # Only run smoke tests for windows against stable chrome. smoke-windows: runs-on: windows-latest @@ -172,3 +172,14 @@ jobs: - name: Run smoke tests run: yarn smoke --debug -j=1 --retries=2 dbw oopif offline lantern metrics + + markdown-link-check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: + use-quiet-mode: 'yes' + use-verbose-mode: 'yes' + config-file: 'markdown.links.config.json' + folder-path: 'docs/' diff --git a/markdown.links.config.json b/markdown.links.config.json new file mode 100644 index 000000000000..9ae2122d2000 --- /dev/null +++ b/markdown.links.config.json @@ -0,0 +1,10 @@ +{ + "ignorePatterns": [ + { + "pattern": "^http://www.tmeter.ru" + }, + { + "pattern": "https://sites.google.com/a/chromium.org/chromedriver/capabilities#TOC-perfLoggingPrefs-object" + } + ] +} From d21ba744cc46f58ebc7435c44c0d94e83c74da05 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 1 Sep 2020 19:49:41 +0300 Subject: [PATCH 02/13] Removed wrongly opened parenthesis from docs/readme.md --- docs/readme.md | 2 +- markdown.links.config.json | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/docs/readme.md b/docs/readme.md index 7a2e6703deed..682c8e0fa11b 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -133,7 +133,7 @@ $ lighthouse --port=9222 --emulated-form-factor=none --throttling.cpuSlowdownMul ## Lighthouse as trace processor -Lighthouse can be used to analyze trace and performance data collected from other tools (like WebPageTest and ChromeDriver). The `traces` and `devtoolsLogs` artifact items can be provided using a string for the absolute path on disk if they're saved with `.trace.json` and `.devtoolslog.json` file extensions, respectively. The `devtoolsLogs` array is captured from the `Network` and `Page` domains (a la ChromeDriver's [enableNetwork and enablePage options]((https://sites.google.com/a/chromium.org/chromedriver/capabilities#TOC-perfLoggingPrefs-object)). +Lighthouse can be used to analyze trace and performance data collected from other tools (like WebPageTest and ChromeDriver). The `traces` and `devtoolsLogs` artifact items can be provided using a string for the absolute path on disk if they're saved with `.trace.json` and `.devtoolslog.json` file extensions, respectively. The `devtoolsLogs` array is captured from the `Network` and `Page` domains (a la ChromeDriver's [enableNetwork and enablePage options](https://sites.google.com/a/chromium.org/chromedriver/capabilities#TOC-perfLoggingPrefs-object)). As an example, here's a trace-only run that reports on user timings and critical request chains: diff --git a/markdown.links.config.json b/markdown.links.config.json index 9ae2122d2000..3dd57b5e0e94 100644 --- a/markdown.links.config.json +++ b/markdown.links.config.json @@ -2,9 +2,6 @@ "ignorePatterns": [ { "pattern": "^http://www.tmeter.ru" - }, - { - "pattern": "https://sites.google.com/a/chromium.org/chromedriver/capabilities#TOC-perfLoggingPrefs-object" } ] } From ee91506d5c7f6d3fe85fb513337100914d22fb97 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 1 Sep 2020 21:14:41 +0300 Subject: [PATCH 03/13] Check links in root readme.md --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 678aaea2d311..fab4db44b9c4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -183,3 +183,4 @@ jobs: use-verbose-mode: 'yes' config-file: 'markdown.links.config.json' folder-path: 'docs/' + file-path: './readme.md' From ad9a004830d8a68614ef9d26dadb67626c4cb6b7 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 1 Sep 2020 22:18:27 +0300 Subject: [PATCH 04/13] Ignore the workflow badge when checking urls --- markdown.links.config.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/markdown.links.config.json b/markdown.links.config.json index 3dd57b5e0e94..c209480ab842 100644 --- a/markdown.links.config.json +++ b/markdown.links.config.json @@ -2,6 +2,9 @@ "ignorePatterns": [ { "pattern": "^http://www.tmeter.ru" + }, + { + "pattern": "https://github.com/GoogleChrome/lighthouse/workflows/\uD83D\uDCA1\uD83C\uDFE0/badge.svg" } ] } From 78384d43738631e0d1080d477e22d33cd6a4f8d2 Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 22:56:33 +0300 Subject: [PATCH 05/13] Moved links checking to a separate yml --- .github/workflows/check-md-links.yml | 30 ++++++++++++++++++++++++++++ .github/workflows/ci.yml | 12 ----------- 2 files changed, 30 insertions(+), 12 deletions(-) create mode 100644 .github/workflows/check-md-links.yml diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml new file mode 100644 index 000000000000..67e272c6157a --- /dev/null +++ b/.github/workflows/check-md-links.yml @@ -0,0 +1,30 @@ +name: markdown-links-check + +on: + push: + #branches: [master] + pull_request: # run on all PRs, not just PRs to a particular branch + +jobs: + check-docs: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: + use-quiet-mode: 'yes' + use-verbose-mode: 'yes' + config-file: 'markdown.links.config.json' + folder-path: 'docs/' + file-path: './readme.md' + + check-root-readme: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: + use-quiet-mode: 'yes' + use-verbose-mode: 'yes' + config-file: 'markdown.links.config.json' + file-path: './readme.md' diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fab4db44b9c4..f2cc82ff3cdf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -172,15 +172,3 @@ jobs: - name: Run smoke tests run: yarn smoke --debug -j=1 --retries=2 dbw oopif offline lantern metrics - - markdown-link-check: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@master - - uses: gaurav-nelson/github-action-markdown-link-check@v1 - with: - use-quiet-mode: 'yes' - use-verbose-mode: 'yes' - config-file: 'markdown.links.config.json' - folder-path: 'docs/' - file-path: './readme.md' From d9eaa8ce9f20ddd1427a0d751b1ed8c27a2aa5c7 Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 22:58:42 +0300 Subject: [PATCH 06/13] Moved links checking to a separate yml --- .github/workflows/check-md-links.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index 67e272c6157a..c9c829c87213 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -18,13 +18,13 @@ jobs: folder-path: 'docs/' file-path: './readme.md' - check-root-readme: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@master - - uses: gaurav-nelson/github-action-markdown-link-check@v1 - with: - use-quiet-mode: 'yes' - use-verbose-mode: 'yes' - config-file: 'markdown.links.config.json' - file-path: './readme.md' + check-root-readme: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: + use-quiet-mode: 'yes' + use-verbose-mode: 'yes' + config-file: 'markdown.links.config.json' + file-path: './readme.md' From 27899fa6dfc65f69d5159f23256d6d4724abd4e0 Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:05:44 +0300 Subject: [PATCH 07/13] Check links only for pull requests --- .github/workflows/check-md-links.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index c9c829c87213..d0394925c635 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -2,7 +2,7 @@ name: markdown-links-check on: push: - #branches: [master] + branches: [master] pull_request: # run on all PRs, not just PRs to a particular branch jobs: From 1ee0d9a1220a046a8a1142c821d5f3b8166ccee8 Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:14:21 +0300 Subject: [PATCH 08/13] Run checklinks actions sequentially --- .github/workflows/check-md-links.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index d0394925c635..c2cd181db337 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -1,8 +1,6 @@ name: markdown-links-check on: - push: - branches: [master] pull_request: # run on all PRs, not just PRs to a particular branch jobs: @@ -19,6 +17,7 @@ jobs: file-path: './readme.md' check-root-readme: + if: success() runs-on: ubuntu-latest steps: - uses: actions/checkout@master From 3af365edb29d7134b7c9cfde126a38fdc2197f8d Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:19:14 +0300 Subject: [PATCH 09/13] Merged markdown links check into a single job --- .github/workflows/check-md-links.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index c2cd181db337..ee9684761682 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -4,7 +4,7 @@ on: pull_request: # run on all PRs, not just PRs to a particular branch jobs: - check-docs: + check-links: runs-on: ubuntu-latest steps: - uses: actions/checkout@master @@ -15,11 +15,6 @@ jobs: config-file: 'markdown.links.config.json' folder-path: 'docs/' file-path: './readme.md' - - check-root-readme: - if: success() - runs-on: ubuntu-latest - steps: - uses: actions/checkout@master - uses: gaurav-nelson/github-action-markdown-link-check@v1 with: From ee10b16403704f1455730ac54ac3d105c6ceba3b Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:24:07 +0300 Subject: [PATCH 10/13] - Changed workflow's name - Removed duplicated readme.md check --- .github/workflows/check-md-links.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index ee9684761682..41a948b2b352 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -1,4 +1,4 @@ -name: markdown-links-check +name: Markdown Links Check on: pull_request: # run on all PRs, not just PRs to a particular branch @@ -14,7 +14,6 @@ jobs: use-verbose-mode: 'yes' config-file: 'markdown.links.config.json' folder-path: 'docs/' - file-path: './readme.md' - uses: actions/checkout@master - uses: gaurav-nelson/github-action-markdown-link-check@v1 with: From a069c9603a78430aeb1e9f39b4e0a2fae6168c9f Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:32:14 +0300 Subject: [PATCH 11/13] - Added cron schedule - Sleep 60 seconds between checks --- .github/workflows/check-md-links.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index 41a948b2b352..b4ca505f6c45 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -1,8 +1,11 @@ name: Markdown Links Check on: + schedule: + - cron: "0 9 * * 1" # run each monday at 9 am pull_request: # run on all PRs, not just PRs to a particular branch + jobs: check-links: runs-on: ubuntu-latest @@ -14,6 +17,9 @@ jobs: use-verbose-mode: 'yes' config-file: 'markdown.links.config.json' folder-path: 'docs/' + - uses: jakejarvis/wait-action@master + with: + time: '60s' - uses: actions/checkout@master - uses: gaurav-nelson/github-action-markdown-link-check@v1 with: From 8a6a550801df3b827c9be7201c5cb2d9583f1492 Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:33:34 +0300 Subject: [PATCH 12/13] - Added cron schedule - Sleep 60 seconds between checks --- .github/workflows/check-md-links.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index b4ca505f6c45..96ae807c4780 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -1,8 +1,8 @@ name: Markdown Links Check on: - schedule: - - cron: "0 9 * * 1" # run each monday at 9 am +# schedule: +# - cron: "0 9 * * 1" # run each monday at 9 am pull_request: # run on all PRs, not just PRs to a particular branch From 5517211967fd238a359be126437979da04ae26a2 Mon Sep 17 00:00:00 2001 From: Andrei Zuica Date: Thu, 3 Sep 2020 23:35:04 +0300 Subject: [PATCH 13/13] - Added cron schedule - Sleep 60 seconds between checks --- .github/workflows/check-md-links.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/check-md-links.yml b/.github/workflows/check-md-links.yml index 96ae807c4780..1adb156494e3 100644 --- a/.github/workflows/check-md-links.yml +++ b/.github/workflows/check-md-links.yml @@ -1,11 +1,8 @@ name: Markdown Links Check on: -# schedule: -# - cron: "0 9 * * 1" # run each monday at 9 am pull_request: # run on all PRs, not just PRs to a particular branch - jobs: check-links: runs-on: ubuntu-latest