# Find Next Phase Number

> Determine the next sequential phase ID for creating a new phase. Use when planning a new phase.

- Skill: `majiayu000/find-next-phase-number` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add majiayu000/find-next-phase-number`
- Raw SKILL.md: https://api.skillmd.com/api/skills/majiayu000/find-next-phase-number/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: majiayu000 (https://skillmd.com/u/majiayu000)
- Updated: 2026-09-09
- Page: https://skillmd.com/skills/majiayu000/find-next-phase-number

---


# Next Phase Number

## How to Find Next ID

Run this command to determine the next available phase number:

```bash
current=$(ls -1 .ushabti/phases/ 2>/dev/null | sed 's/-.*//' | sort -n | tail -1)
if [ -z "$current" ]; then
  echo "0001 (first phase)"
else
  printf "%04d (after %s)\n" $((10#$current + 1)) "$current"
fi
```

## Phase Numbering Convention

- Phase IDs are 4-digit, zero-padded integers: `0001`, `0002`, `0003`, ...
- Combined with a slug: `0001-initial-setup`, `0002-add-auth`, ...

## Creating the Directory

Once you have the next number and a slug:
```bash
mkdir -p .ushabti/phases/NNNN-your-slug
```

Replace `NNNN` with the next ID and `your-slug` with a short, lowercase, hyphenated description.

