From 6a8457f42c70f724b64e6896772966c30ed59a03 Mon Sep 17 00:00:00 2001 From: Leandro Lucarella Date: Wed, 24 Jul 2024 09:27:04 +0200 Subject: [PATCH] Group dependabot updates for GitHub Actions Group patch and minor updates, as well as any release for the upload/download artifact actions, that need to be upgraded always together. Signed-off-by: Leandro Lucarella --- .github/dependabot.yml | 8 +++++++ RELEASE_NOTES.md | 2 +- cookiecutter/migrate.sh | 22 +++++++++++++++++-- .../.github/dependabot.yml | 8 +++++++ .../.github/dependabot.yml | 8 +++++++ .../frequenz-api-test/.github/dependabot.yml | 8 +++++++ .../frequenz-app-test/.github/dependabot.yml | 8 +++++++ .../.github/dependabot.yml | 8 +++++++ .../.github/dependabot.yml | 8 +++++++ 9 files changed, 77 insertions(+), 3 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index d9456c45..53bdd6c3 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -39,3 +39,11 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact" diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 4a01ccc2..b697a370 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -18,7 +18,7 @@ ### Cookiecutter template - +* Group GitHub Actions dependabot updates. ## Bug Fixes diff --git a/cookiecutter/migrate.sh b/cookiecutter/migrate.sh index 81f1ed0c..2916d8de 100644 --- a/cookiecutter/migrate.sh +++ b/cookiecutter/migrate.sh @@ -22,9 +22,27 @@ manual_step() { echo "\033[0;33m>>> $@\033[0m" } -echo "TODO: Describe your migration step here." +#echo "TODO: Describe your migration step here." # Add your migration steps here. -manual_step "Add any manual instructions for this step here." +#manual_step "Add any manual instructions for this step here." + +echo "dependabot: Group GitHub Actions updates." +cat <<'EOT' | patch -p1 +--- a/.github/dependabot.yml ++++ b/.github/dependabot.yml +@@ -39,3 +39,11 @@ updates: + labels: + - "part:tooling" + - "type:tech-debt" ++ groups: ++ compatible: ++ update-types: ++ - "minor" ++ - "patch" ++ artifacts: ++ patterns: ++ - "actions/*-artifact" +EOT # Add a separation line like this one after each migration step. echo "========================================================================" diff --git a/cookiecutter/{{cookiecutter.github_repo_name}}/.github/dependabot.yml b/cookiecutter/{{cookiecutter.github_repo_name}}/.github/dependabot.yml index 9f90cb7b..cfeaac00 100644 --- a/cookiecutter/{{cookiecutter.github_repo_name}}/.github/dependabot.yml +++ b/cookiecutter/{{cookiecutter.github_repo_name}}/.github/dependabot.yml @@ -39,6 +39,14 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact" {%- if cookiecutter.type == "api" %} - package-ecosystem: "gitsubmodule" diff --git a/tests_golden/integration/test_cookiecutter_generation/actor/frequenz-actor-test/.github/dependabot.yml b/tests_golden/integration/test_cookiecutter_generation/actor/frequenz-actor-test/.github/dependabot.yml index 8978cb3c..23cd21b1 100644 --- a/tests_golden/integration/test_cookiecutter_generation/actor/frequenz-actor-test/.github/dependabot.yml +++ b/tests_golden/integration/test_cookiecutter_generation/actor/frequenz-actor-test/.github/dependabot.yml @@ -39,3 +39,11 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact" diff --git a/tests_golden/integration/test_cookiecutter_generation/api/frequenz-api-test/.github/dependabot.yml b/tests_golden/integration/test_cookiecutter_generation/api/frequenz-api-test/.github/dependabot.yml index 24b56348..d98b4f33 100644 --- a/tests_golden/integration/test_cookiecutter_generation/api/frequenz-api-test/.github/dependabot.yml +++ b/tests_golden/integration/test_cookiecutter_generation/api/frequenz-api-test/.github/dependabot.yml @@ -39,6 +39,14 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact" - package-ecosystem: "gitsubmodule" directory: "/" diff --git a/tests_golden/integration/test_cookiecutter_generation/app/frequenz-app-test/.github/dependabot.yml b/tests_golden/integration/test_cookiecutter_generation/app/frequenz-app-test/.github/dependabot.yml index 8978cb3c..23cd21b1 100644 --- a/tests_golden/integration/test_cookiecutter_generation/app/frequenz-app-test/.github/dependabot.yml +++ b/tests_golden/integration/test_cookiecutter_generation/app/frequenz-app-test/.github/dependabot.yml @@ -39,3 +39,11 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact" diff --git a/tests_golden/integration/test_cookiecutter_generation/lib/frequenz-test-python/.github/dependabot.yml b/tests_golden/integration/test_cookiecutter_generation/lib/frequenz-test-python/.github/dependabot.yml index 8978cb3c..23cd21b1 100644 --- a/tests_golden/integration/test_cookiecutter_generation/lib/frequenz-test-python/.github/dependabot.yml +++ b/tests_golden/integration/test_cookiecutter_generation/lib/frequenz-test-python/.github/dependabot.yml @@ -39,3 +39,11 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact" diff --git a/tests_golden/integration/test_cookiecutter_generation/model/frequenz-model-test/.github/dependabot.yml b/tests_golden/integration/test_cookiecutter_generation/model/frequenz-model-test/.github/dependabot.yml index 8978cb3c..23cd21b1 100644 --- a/tests_golden/integration/test_cookiecutter_generation/model/frequenz-model-test/.github/dependabot.yml +++ b/tests_golden/integration/test_cookiecutter_generation/model/frequenz-model-test/.github/dependabot.yml @@ -39,3 +39,11 @@ updates: labels: - "part:tooling" - "type:tech-debt" + groups: + compatible: + update-types: + - "minor" + - "patch" + artifacts: + patterns: + - "actions/*-artifact"