chore(repo): automatically delete head branches is off, so merged branches pile up

Open Beginner friendly
#20 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
Under an hour
Newbie friendliness
60/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
github, github-actions
Domain
devops

Research direction

Start by confirming the current state with gh api repos/flisk-sh/analytics --jq .delete_branch_on_merge; the payload already shows it returns false. The fix itself is a repo setting change (gh repo edit --delete-branch-on-merge) that requires admin rights, so a newcomer will likely need a maintainer to run it. For the code half, add a small check under .github/workflows/ that reads that field and fails when false. Done when the flag is true, merged branches are pruned, and the workflow passes.

Written by the indexing model from the issue text.

Description

agents area: runtime automation chore cli consistency dependencies developer-experience difficulty: easy documentation enhancement good first issue help wanted hygiene json-output priority: P3 starters tests

Problem

flisk-sh/analytics has "Automatically delete head branches" turned off. Every merged pull request leaves its branch behind, so the branch list fills with stale branches that contributors then have to sort through (and that look like unfinished work).

Repro:

gh api repos/flisk-sh/analytics --jq .delete_branch_on_merge
# false

Root Cause Analysis

The repo setting was left at the GitHub default (off). It is a one-click repo setting, not a code change.

TDD Fix Plan

  1. RED: Add a small org-settings check (script or workflow) that fails when delete_branch_on_merge is false.
    GREEN: Enable "Automatically delete head branches" in the repo settings (gh repo edit --delete-branch-on-merge).

REFACTOR: None expected.

Acceptance Criteria

  • delete_branch_on_merge is true
  • Existing merged branches are cleaned up
  • All new tests pass
  • Existing tests still pass
Dominant language
JavaScript
Stars
0
Forks
2
Avg merge
1h 33m
Merged PRs (30d)
7

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from flisk-sh/analytics

All issues in flisk-sh/analytics

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.