From 6559de4901ce86e0527763019704fc0efd39e875 Mon Sep 17 00:00:00 2001 From: Jolien Trog Date: Fri, 11 Jul 2025 13:46:36 +0200 Subject: [PATCH 1/5] Configure Stale Action workflow for automatic closing of outdated issues --- .github/workflows/stale.yml | 39 +++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 .github/workflows/stale.yml diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml new file mode 100644 index 0000000..1fba616 --- /dev/null +++ b/.github/workflows/stale.yml @@ -0,0 +1,39 @@ +# Stale Action + +#This action automatically closes old issues to maintain repository cleanup +#Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NP' are skipped. +# days-before-issue-stale: Days until issue gets 'stale' label +# days-before-issue-close: 0: Issues are closed immediately after being labeled stale +# operations-per-run: 15: Max ~5 issues processed per run (3 operations each) +# ascending: true: Processes oldest issues first +# ignore-issue-updates: true: Closes issues regardless of recent activity +# debug-only: action only simulates the labeling and closing process, useful for testing +# Reopen: Automatically closed issues must be manually reopened if still relevant, and the 'stale' label removed to prevent reprocessing. + +name: 'stale' + +permissions: + issues: write + +on: + schedule: + - cron: 0 13 * * 1-5 + +jobs: + stale: + runs-on: ubuntu-latest + steps: + - uses: actions/stale@v9 + with: + close-issue-message: 'This issue has been automatically closed due to age/inactivity. If still relevant with current software version, feel free to create a new issue with updated details. ' + stale-issue-label: 'stale' + exempt-issue-labels: 'ref/IP, ref/NP' + exempt-all-issue-milestones: true + days-before-issue-stale: 1780 + days-before-issue-close: 0 + operations-per-run: 15 + enable-statistics: true + ignore-issue-updates: true + ascending: true + debug-only: true + \ No newline at end of file From 66278109e824c1de691606b4239d11c1779f2d88 Mon Sep 17 00:00:00 2001 From: Jolien Trog Date: Fri, 11 Jul 2025 13:48:41 +0200 Subject: [PATCH 2/5] Configure Stale Action workflow for automatic closing of outdated issues --- .github/workflows/stale.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 1fba616..dc7af8a 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -1,7 +1,7 @@ # Stale Action -#This action automatically closes old issues to maintain repository cleanup -#Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NP' are skipped. +# This action automatically closes old issues to maintain repository cleanup +# Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NP' are skipped. # days-before-issue-stale: Days until issue gets 'stale' label # days-before-issue-close: 0: Issues are closed immediately after being labeled stale # operations-per-run: 15: Max ~5 issues processed per run (3 operations each) @@ -36,4 +36,3 @@ jobs: ignore-issue-updates: true ascending: true debug-only: true - \ No newline at end of file From 366abc43b8ae7376a6e1972073d22f3d03196611 Mon Sep 17 00:00:00 2001 From: Jolien Trog Date: Wed, 6 Aug 2025 18:54:35 +0200 Subject: [PATCH 3/5] fix typo in label name --- .github/workflows/stale.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index dc7af8a..497d7be 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -27,7 +27,7 @@ jobs: with: close-issue-message: 'This issue has been automatically closed due to age/inactivity. If still relevant with current software version, feel free to create a new issue with updated details. ' stale-issue-label: 'stale' - exempt-issue-labels: 'ref/IP, ref/NP' + exempt-issue-labels: 'ref/IP, ref/NC' exempt-all-issue-milestones: true days-before-issue-stale: 1780 days-before-issue-close: 0 From 7641eb1feec49e18578179a1596e738a65410c2a Mon Sep 17 00:00:00 2001 From: Jolien Trog Date: Mon, 11 Aug 2025 19:55:41 +0200 Subject: [PATCH 4/5] Fix parameters to exclude PRs and add explanation --- .github/workflows/stale.yml | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-) diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 497d7be..191cd95 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -1,14 +1,26 @@ # Stale Action # This action automatically closes old issues to maintain repository cleanup -# Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NP' are skipped. -# days-before-issue-stale: Days until issue gets 'stale' label +# Cron runs the job at 13:00 German local time (CET/CEST) +# GitHub Actions cron uses UTC, so the time is set to 11:00 UTC. +# Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NC' are skipped. +# days-before-issue-stale: Days until issue gets 'stale' label. +# Set to 1304 days to represent 5 years of working days (Mon–Fri), +# because the cron job only runs on weekdays. # days-before-issue-close: 0: Issues are closed immediately after being labeled stale -# operations-per-run: 15: Max ~5 issues processed per run (3 operations each) +# days-before-pr-stale: -1: disables marking pull requests as stale and overrides +# the default (60 days) +# days-before-pr-close: -1: Disables automatically closing pull requests after being marked stale +# operations-per-run: 15 limits total API operations per run; +# since each issue needs 3 operations (label, message, close), +# max ~5 issues are processed per run. +# The action limits operations, not issues directly, so changing config +# (e.g., adding more labels or comments) affects how many issues can be handled in one run. # ascending: true: Processes oldest issues first # ignore-issue-updates: true: Closes issues regardless of recent activity # debug-only: action only simulates the labeling and closing process, useful for testing -# Reopen: Automatically closed issues must be manually reopened if still relevant, and the 'stale' label removed to prevent reprocessing. +# Reopen: Automatically closed issues must be manually reopened if still relevant, +# and the 'stale' label removed to prevent reprocessing. name: 'stale' @@ -17,7 +29,7 @@ permissions: on: schedule: - - cron: 0 13 * * 1-5 + - cron: 0 11 * * 1-5 jobs: stale: @@ -25,12 +37,17 @@ jobs: steps: - uses: actions/stale@v9 with: - close-issue-message: 'This issue has been automatically closed due to age/inactivity. If still relevant with current software version, feel free to create a new issue with updated details. ' + close-issue-message: > + 'This issue has been automatically closed due to age/inactivity. + If still relevant with current software version, + feel free to create a new issue with updated details. ' stale-issue-label: 'stale' exempt-issue-labels: 'ref/IP, ref/NC' exempt-all-issue-milestones: true - days-before-issue-stale: 1780 + days-before-issue-stale: 1304 days-before-issue-close: 0 + days-before-pr-stale: -1 + days-before-pr-close: -1 operations-per-run: 15 enable-statistics: true ignore-issue-updates: true From 852b1d4d797222eb84ff33b2e6974872beef2edc Mon Sep 17 00:00:00 2001 From: Jolien Trog Date: Tue, 12 Aug 2025 09:28:02 +0200 Subject: [PATCH 5/5] fix time period for stale label and codoe-comments --- .github/workflows/stale.yml | 50 +++++++++++++++++++++---------------- 1 file changed, 29 insertions(+), 21 deletions(-) diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 191cd95..3f0197c 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -1,32 +1,17 @@ # Stale Action # This action automatically closes old issues to maintain repository cleanup -# Cron runs the job at 13:00 German local time (CET/CEST) -# GitHub Actions cron uses UTC, so the time is set to 11:00 UTC. -# Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NC' are skipped. -# days-before-issue-stale: Days until issue gets 'stale' label. -# Set to 1304 days to represent 5 years of working days (Mon–Fri), -# because the cron job only runs on weekdays. -# days-before-issue-close: 0: Issues are closed immediately after being labeled stale -# days-before-pr-stale: -1: disables marking pull requests as stale and overrides -# the default (60 days) -# days-before-pr-close: -1: Disables automatically closing pull requests after being marked stale -# operations-per-run: 15 limits total API operations per run; -# since each issue needs 3 operations (label, message, close), -# max ~5 issues are processed per run. -# The action limits operations, not issues directly, so changing config -# (e.g., adding more labels or comments) affects how many issues can be handled in one run. -# ascending: true: Processes oldest issues first -# ignore-issue-updates: true: Closes issues regardless of recent activity -# debug-only: action only simulates the labeling and closing process, useful for testing # Reopen: Automatically closed issues must be manually reopened if still relevant, # and the 'stale' label removed to prevent reprocessing. name: 'stale' +# If the permissions are restricted, the action could require more permission permissions: issues: write +# Cron runs the job at 13:00 German local time (CET/CEST) +# GitHub Actions cron uses UTC, so the time is set to 11:00 UTC. on: schedule: - cron: 0 11 * * 1-5 @@ -42,14 +27,37 @@ jobs: If still relevant with current software version, feel free to create a new issue with updated details. ' stale-issue-label: 'stale' + + # Exemptions: Issues with milestones or labels 'ref/IP', 'ref/NC' are skipped. exempt-issue-labels: 'ref/IP, ref/NC' - exempt-all-issue-milestones: true - days-before-issue-stale: 1304 + + # Milestones on issues/PRs exempted from stale + exempt-milestones: true + + # Days until issue gets 'stale' label (updated_at) + days-before-issue-stale: 1825 + + # Issues are closed immediately after being labeled stale days-before-issue-close: 0 + + # Disables marking pull requests as stale and overrides + # the default (60 days) days-before-pr-stale: -1 + + # Disables automatically closing pull requests after being marked stale days-before-pr-close: -1 + + # Limits total API operations per run; + # since each issue needs 3 operations (label, message, close), + # max ~5 issues are processed per run. + # The action limits operations, not issues directly, so changing config + # (e.g., adding more labels or comments) affects + # how many issues can be handled in one run. operations-per-run: 15 enable-statistics: true - ignore-issue-updates: true + + # Processes oldest issues first ascending: true + + # Action only simulates the labeling and closing process, useful for testing debug-only: true