Agent skill

Next Issue Number

by oocx in oocx/tfplan2md

Determine the next available issue number across all change types (feature, fix, workflow, website) by checking both local docs and remote branches, then reserve it by pushing an empty branch.

MITAuto-check passedDevelopment

Install Next Issue Number

skills CLI
$ npx skills add oocx/tfplan2md --skill next-issue-number -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install oocx/tfplan2md next-issue-number --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/oocx/tfplan2md.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/next-issue-number .claude/skills/next-issue-number && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
next-issue-number
GitHub stars
174
Token cost
~1.5k tokens
SKILL.md length
546 words
Files
2 (incl. scripts)
Skills in repo
28
Repo updated
First seen
Licence
MIT

At a glance

Determine the next available issue number across all change types (feature, fix, workflow, website) by checking both local docs and remote branches, then reserve it by pushing an empty branch.

  • Works in 5 steps: Finding the highest number used in local… → Finding the highest number used in… → Finding the highest number used in… → …
  • Development work in your project
  • SKILL.md covers Purpose, Session Start Hook, Hard Rules and Golden Example, plus 3 more sections
  • Runs Shell scripts from its folder; calls git

What it does

Next Issue Number is an agent skill from oocx/tfplan2md. Determine the next available issue number across all change types (feature, fix, workflow, website) by checking both local docs and remote branches, then reserve it by pushing an empty branch.

Its SKILL.md is about 1.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including scripts (for example `scripts/next-issue-number.sh`).

It sits in Development. It works with GitHub. The repository describes itself as: Convert terraform plans (json) into human readable markdown for easier review of changes in pull requests. The licence is MIT.

When your agent uses it

  • Development work in your project

Example prompts

  • “/next-issue-number”

Requirements

  • A Bash shell

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. Finding the highest number used in local docs folders (docs/features/, docs/issues/, docs/workflow/)
  2. Finding the highest number used in remote branches on GitHub (feature/NNN-*, fix/NNN-*, workflow/NNN-*)
  3. Finding the highest number used in recent copilot/* remote branches (less than one week old)
  4. Calculating the next available number (max + 1)
  5. Immediately pushing the new branch to GitHub to reserve the number for other agents

What it can do on your machine

Read from SKILL.md and the folder at commit 88d5240. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (Shell), which the agent can run.

    Shell commands in SKILL.md call:

    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Next Issue Number loads about 1.5k tokens when it runs. Until then it costs about 53 tokens; SKILL.md has 546 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~53
When it runs · the whole SKILL.md, loaded when a task matches
~1.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from oocx/tfplan2md at commit 88d5240, republished under its MIT licence (© oocx). 546 words, ~1,527 tokens.

Download SKILL.mdSave it as .claude/skills/next-issue-number/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
next-issue-number
description
Determine the next available issue number across all change types (feature, fix, workflow, website) by checking both local docs and remote branches, then reserve it by pushing an empty branch.

Skill Instructions

Purpose

Ensure unique issue numbering across all change types (feature, fix, workflow, website) by:

  1. Finding the highest number used in local docs folders (docs/features/, docs/issues/, docs/workflow/)
  2. Finding the highest number used in remote branches on GitHub (feature/NNN-, fix/NNN-, workflow/NNN-*)
  3. Finding the highest number used in recent copilot/* remote branches (less than one week old)
  4. Calculating the next available number (max + 1)
  5. Immediately pushing the new branch to GitHub to reserve the number for other agents

This prevents duplicate issue numbers when multiple agents work concurrently or when work-in-progress exists on remote branches but not yet in main.

Session Start Hook

A SessionStart hook (declared in .agents/claude-settings.json) automatically runs scripts/next-issue-number.sh when a new agent session begins and writes the result to .next-issue-number. This means the next issue number is pre-calculated for you at session start.

Read the pre-calculated value first (fast, no network call required):

bash
if [ -f .next-issue-number ]; then
    NEXT_NUMBER=$(cat .next-issue-number)
else
    NEXT_NUMBER=$(scripts/next-issue-number.sh)
fi
echo "Next issue number: $NEXT_NUMBER"

The .next-issue-number file is gitignored and refreshed each session. If it is missing or stale, fall back to running the script directly.

Hard Rules

Must
  • Check ALL change types (feature, fix, workflow), not just one type
  • Check both local docs folders AND remote GitHub branches (including recent copilot/* branches)
  • Use the helper script scripts/next-issue-number.sh which handles all lookups
  • Push the new branch immediately after creation (before making any changes) to reserve the number
  • Format the number as 3 digits with leading zeros (e.g., 033, 034, 035)
  • Minimize Maintainer approvals by using a single stable wrapper script
Must Not
  • Only check one change type (e.g., only features)
  • Skip checking remote branches
  • Delay pushing the branch until after making changes
  • Assume the next number based on local state alone

Golden Example

bash
# Step 1: Determine the next issue number (prefer pre-calculated value from session hook)
if [ -f .next-issue-number ]; then
    NEXT_NUMBER=$(cat .next-issue-number)
else
    NEXT_NUMBER=$(scripts/next-issue-number.sh)
fi
echo "Next issue number: $NEXT_NUMBER"

# Step 2: Create the branch with the determined number
git fetch origin && git switch main && git pull --ff-only origin main
git switch -c feature/${NEXT_NUMBER}-my-feature-name

# Step 3: IMMEDIATELY push to reserve the number
git push -u origin HEAD

# Now proceed with your work...

Actions

For Requirements Engineer (New Features)
  1. Before creating a feature branch, get the next number:

    bash
    if [ -f .next-issue-number ]; then
        NEXT_NUMBER=$(cat .next-issue-number)
    else
        NEXT_NUMBER=$(scripts/next-issue-number.sh)
    fi
  2. Update and switch to main:

    bash
    git fetch origin && git switch main && git pull --ff-only origin main
  3. Create the feature branch with the determined number:

    bash
    git switch -c feature/${NEXT_NUMBER}-<short-description>
  4. IMMEDIATELY push the branch to reserve the number:

    bash
    git push -u origin HEAD
  5. Proceed with gathering requirements and creating the specification

Show full SKILL.md (283 more words)Show less
For Issue Analyst (Bug Fixes)
  1. Before creating a fix branch, get the next number:

    bash
    if [ -f .next-issue-number ]; then
        NEXT_NUMBER=$(cat .next-issue-number)
    else
        NEXT_NUMBER=$(scripts/next-issue-number.sh)
    fi
  2. Update and switch to main:

    bash
    git fetch origin && git switch main && git pull --ff-only origin main
  3. Create the fix branch with the determined number:

    bash
    git switch -c fix/${NEXT_NUMBER}-<short-description>
  4. IMMEDIATELY push the branch to reserve the number:

    bash
    git push -u origin HEAD
  5. Proceed with issue investigation and analysis

For Workflow Engineer (Workflow Improvements)
  1. Before creating a workflow branch, get the next number:

    bash
    if [ -f .next-issue-number ]; then
        NEXT_NUMBER=$(cat .next-issue-number)
    else
        NEXT_NUMBER=$(scripts/next-issue-number.sh)
    fi
  2. Update and switch to main:

    bash
    git fetch origin && git switch main && git pull --ff-only origin main
  3. Create the workflow branch with the determined number:

    bash
    git switch -c workflow/${NEXT_NUMBER}-<short-description>
  4. IMMEDIATELY push the branch to reserve the number:

    bash
    git push -u origin HEAD
  5. Proceed with workflow improvements

Troubleshooting

If GitHub authentication fails

The script will fall back to checking only local docs folders and warn you:

Warning: Could not fetch from GitHub. Using local data only.
Next available number based on local docs: 033

In this case, manually verify on GitHub that no higher numbers exist in remote branches.

If the calculated number already exists

The script checks local docs, named branches, and recent copilot/* branches. If it still returns a number that exists:

  1. Verify the script ran correctly: scripts/next-issue-number.sh
  2. Check if someone pushed a new branch since you ran the script
  3. Delete your branch and re-run the script to get a fresh number

Verification

After running the script and pushing your branch:

  1. Verify the branch exists on GitHub: git ls-remote origin | grep "refs/heads/\(feature\|fix\|workflow\)/${NEXT_NUMBER}-"
  2. Confirm no docs folder exists yet: ls -d docs/{features,issues,workflow}/${NEXT_NUMBER}-* 2>/dev/null (should be empty)

© oocx, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (scripts) in .agents/skills/next-issue-number of oocx/tfplan2md.

  • SKILL.md
  • scripts/next-issue-number.sh

Open the folder on GitHubat commit 88d5240

Compare with similar skills

Next Issue Number next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Next Issue Number compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Next Issue Number this skilloocx/tfplan2md174—~1.5kAutomated safety check: PassMIT
PR Babysitteropeninterpreter/openinterpreter69k3 repos~4.2kAutomated safety check: PassApache-2.0
Mole CLI Release Flowtw93/Mole70k—~2.5kAutomated safety check: PassGPL-3.0
Ansible Backport Creatoransible/ansible71k—~1.2kAutomated safety check: PassGPL-3.0
Hunk Release Workflowmodem-dev/hunk9.5k—~3.8kAutomated safety check: PassMIT
Worktrunk Release Workflowmax-sixty/worktrunk9k—~6.9kAutomated safety check: PassCustom licence

Similar skills

  • PR Babysitter

    openinterpreter/openinterpreter

    Watches an open GitHub pull request until it merges, handling review comments, diagnosing CI failures and retrying flaky checks along the way.

    69k GitHub starsUsed in 3 repos~4.2k tokens
    DevelopmentAuto-check passed
  • Runbook for assessing and executing a Mole CLI release: distribution channels, pre-flight checks, capital-V tags, build artifacts and the handoff to curated release notes.

    70k GitHub stars~2.5k tokensUpdated today
    DevelopmentAuto-check passed
  • Creates backports of a merged Ansible devel pull request onto the right stable branches by cherry-picking its merge commit onto new backport branches.

    71k GitHub stars~1.2k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Hunk Release Workflow

    modem-dev/hunk

    Maintainer workflow for preparing, publishing, verifying and curating Hunk releases, with confirmation gates before tags, publishes and public edits.

    9.5k GitHub stars~3.8k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Worktrunk Release Workflow

    max-sixty/worktrunk

    Walks a maintainer through cutting a Worktrunk release: sync the release branch, pass two test gates, review the changes, then publish.

    9k GitHub stars~6.9k tokensUpdated today
    DevelopmentAuto-check passed
  • CI Act Run

    chewiebug/GCViewer

    Run the full build-and-deploy.yaml workflow locally via act + Docker.

    4.6k GitHub stars~2.4k tokensUpdated 3 mo ago
    DevelopmentAuto-check: notes

More from oocx/tfplan2md

All 28 skills in this repo
  • Create Agent Skill

    oocx/tfplan2md

    Create a new Agent Skill following project standards and templates.

    174 GitHub stars~1.5k tokensUpdated today
    Auto-check passed
  • Detect and analyze edge crossings and overlaps in SVG workflow diagrams using geometric intersection algorithms and visual analysis.

    174 GitHub stars~4.3k tokensUpdated today
    Auto-check passed
  • Generate PNG screenshots for release notes using the repository's HtmlRenderer and ScreenshotGenerator tools.

    174 GitHub stars~3.7k tokensUpdated today
    Auto-check passed
  • Git Rebase Main

    oocx/tfplan2md

    Safely rebase the current feature branch on top of the latest origin/main.

    174 GitHub stars~456 tokensUpdated today
    Auto-check passed
  • Run Uat

    oocx/tfplan2md

    Run User Acceptance Testing by creating a PR with rendered markdown on GitHub or Azure DevOps.

    174 GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Convert the mermaid diagram in docs/workflow.md to a blueprint-styled SVG for the website.

    174 GitHub stars~1.3k tokensUpdated today
    Auto-check passed

Works with

Questions about Next Issue Number

What does Next Issue Number do?

Determine the next available issue number across all change types (feature, fix, workflow, website) by checking both local docs and remote branches, then reserve it by pushing an empty branch. Next Issue Number is an agent skill from oocx/tfplan2md. Determine the next available issue number across all change types (feature, fix, workflow, website) by checking both local docs and remote branches, then reserve it by pushing an empty branch.

When should I use Next Issue Number?

Next Issue Number fits situations like: development work in your project.

How do I install Next Issue Number in Claude Code?

Run `npx skills add oocx/tfplan2md --skill next-issue-number -a claude-code`. Or copy the skill folder (.agents/skills/next-issue-number in oocx/tfplan2md) into .claude/skills/next-issue-number in your project. Claude Code loads it when a task matches its description.

How do I install Next Issue Number in Codex?

Run `npx skills add oocx/tfplan2md --skill next-issue-number -a codex`. Or copy the skill folder (.agents/skills/next-issue-number in oocx/tfplan2md) into .agents/skills/next-issue-number in your project. Codex loads it when a task matches its description.

Can I use Next Issue Number in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add oocx/tfplan2md --skill next-issue-number -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/next-issue-number, .gemini/skills/next-issue-number, .github/skills/next-issue-number and .opencode/skills/next-issue-number in your project.

What does Next Issue Number need to run?

Going by SKILL.md and its folder, Next Issue Number needs a shell for the scripts in its folder and the command-line tools its instructions call (git). Our summary lists: A Bash shell.

Does Next Issue Number access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Next Issue Number safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Next Issue Number use?

Next Issue Number is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Next Issue Number use?

About 1.5k tokens (SKILL.md is roughly 6.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Next Issue Number?

Skills that share tags, products or a category with Next Issue Number: PR Babysitter (openinterpreter/openinterpreter, 69k stars), Mole CLI Release Flow (tw93/Mole, 70k stars), Ansible Backport Creator (ansible/ansible, 71k stars) and Hunk Release Workflow (modem-dev/hunk, 9.5k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Next Issue Number?

oocx (a GitHub user) maintains it in oocx/tfplan2md, which has 174 GitHub stars. The repository holds 28 skills in this directory. The repository was last updated on October 7, 2026.

Source: oocx/tfplan2md on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.