원클릭으로
next-issue-number
// Determine the next available issue number across all change types (feature, fix, workflow) by checking both local docs and remote branches, then reserve it by pushing an empty branch.
// Determine the next available issue number across all change types (feature, fix, workflow) by checking both local docs and remote branches, then reserve it by pushing an empty branch.
Minimum-requirements checklist for any change — code or docs-only. Run this before every PR creation or push to avoid CI failures on the first attempt.
Generate PNG screenshots for release notes using the repository's HtmlRenderer and ScreenshotGenerator tools. Use when asked to add screenshots to release notes or documentation.
Convert the mermaid diagram in docs/agents.md to a blueprint-styled SVG for the website. Use when the workflow diagram in agents.md is updated and needs to be reflected on the website.
Run a focused accessibility pass for website changes (WCAG 2.1 AA-oriented).
Create and update interactive examples for the Eleventy website using page entrypoints and src/examples fragments.
Use browser tools to inspect rendering and troubleshoot website issues with the Maintainer.
| name | next-issue-number |
| description | Determine the next available issue number across all change types (feature, fix, workflow) by checking both local docs and remote branches, then reserve it by pushing an empty branch. |
Ensure unique issue numbering across all change types (feature, fix, workflow) by:
copilot/* remote branches (less than one week old)This prevents duplicate issue numbers when multiple agents work concurrently or when work-in-progress exists on remote branches but not yet in main.
A sessionStart hook (.github/hooks/session-start.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):
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.
scripts/next-issue-number.sh which handles all lookups# 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...
if [ -f .next-issue-number ]; then
NEXT_NUMBER=$(cat .next-issue-number)
else
NEXT_NUMBER=$(scripts/next-issue-number.sh)
fi
git fetch origin && git switch main && git pull --ff-only origin main
git switch -c feature/${NEXT_NUMBER}-<short-description>
git push -u origin HEAD
if [ -f .next-issue-number ]; then
NEXT_NUMBER=$(cat .next-issue-number)
else
NEXT_NUMBER=$(scripts/next-issue-number.sh)
fi
git fetch origin && git switch main && git pull --ff-only origin main
git switch -c fix/${NEXT_NUMBER}-<short-description>
git push -u origin HEAD
if [ -f .next-issue-number ]; then
NEXT_NUMBER=$(cat .next-issue-number)
else
NEXT_NUMBER=$(scripts/next-issue-number.sh)
fi
git fetch origin && git switch main && git pull --ff-only origin main
git switch -c workflow/${NEXT_NUMBER}-<short-description>
git push -u origin HEAD
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.
The script checks local docs, named branches, and recent copilot/* branches. If it still returns a number that exists:
scripts/next-issue-number.shAfter running the script and pushing your branch:
git ls-remote origin | grep "refs/heads/\(feature\|fix\|workflow\)/${NEXT_NUMBER}-"ls -d docs/{features,issues,workflow}/${NEXT_NUMBER}-* 2>/dev/null (should be empty)