From 4c3740eb45958e125c91bfb19ee93053371454ec Mon Sep 17 00:00:00 2001 From: rhysd Date: Wed, 22 May 2024 13:07:55 +0900 Subject: [PATCH] remove `windows-2016` runner label support which was dropped in 2022 https://github.blog/changelog/2021-10-19-github-actions-the-windows-2016-runner-image-will-be-removed-from-github-hosted-runners-on-march-15-2022/ --- docs/checks.md | 6 +++--- rule_runner_label.go | 5 +---- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/docs/checks.md b/docs/checks.md index 15498492a..82fa9f379 100644 --- a/docs/checks.md +++ b/docs/checks.md @@ -1572,15 +1572,15 @@ jobs: Output: ``` -test.yaml:10:13: label "linux-latest" is unknown. available labels are "windows-latest", "windows-2022", "windows-2019", "windows-2016", "ubuntu-latest", ... [runner-label] +test.yaml:10:13: label "linux-latest" is unknown. available labels are "windows-latest", "windows-2022", "windows-2019", "ubuntu-latest", ... [runner-label] | 10 | - linux-latest | ^~~~~~~~~~~~ -test.yaml:16:13: label "gpu" is unknown. available labels are "windows-latest", "windows-2022", "windows-2019", "windows-2016", "ubuntu-latest", ... [runner-label] +test.yaml:16:13: label "gpu" is unknown. available labels are "windows-latest", "windows-2022", "windows-2019", "ubuntu-latest", ... [runner-label] | 16 | - gpu | ^~~ -test.yaml:23:14: label "macos-10.13" is unknown. available labels are "windows-latest", "windows-2022", "windows-2019", "windows-2016", "ubuntu-latest", ... [runner-label] +test.yaml:23:14: label "macos-10.13" is unknown. available labels are "windows-latest", "windows-2022", "windows-2019", "ubuntu-latest", ... [runner-label] | 23 | runs-on: macos-10.13 | ^~~~~~~~~~~ diff --git a/rule_runner_label.go b/rule_runner_label.go index 8cb047066..ef5646697 100644 --- a/rule_runner_label.go +++ b/rule_runner_label.go @@ -22,7 +22,6 @@ const ( compatMacOS140 compatMacOS140L compatMacOS140XL - compatWindows2016 compatWindows2019 compatWindows2022 ) @@ -33,7 +32,6 @@ var allGitHubHostedRunnerLabels = []string{ "windows-latest-8-cores", "windows-2022", "windows-2019", - "windows-2016", "ubuntu-latest", "ubuntu-latest-4-cores", "ubuntu-latest-8-cores", @@ -112,10 +110,9 @@ var defaultRunnerOSCompats = map[string]runnerOSCompat{ "windows-latest-8-cores": compatWindows2022, "windows-2022": compatWindows2022, "windows-2019": compatWindows2019, - "windows-2016": compatWindows2016, "linux": compatUbuntu2404 | compatUbuntu2204 | compatUbuntu2004, // Note: "linux" does not always indicate Ubuntu. It might be Fedora or Arch or ... "macos": compatMacOS140 | compatMacOS140L | compatMacOS140XL | compatMacOS130 | compatMacOS130L | compatMacOS130XL | compatMacOS120 | compatMacOS120L | compatMacOS120XL | compatMacOS110, - "windows": compatWindows2022 | compatWindows2019 | compatWindows2016, + "windows": compatWindows2022 | compatWindows2019, } // RuleRunnerLabel is a rule to check runner label like "ubuntu-latest". There are two types of