Skip to content
Back to skills

Issue Close Migrated

ASecurity

Close an issue as status:migrated or status:cancelled with --reason "not planned". Applies label, posts comment, and closes.

  • 3 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 7, 2026
toolsshellbashgit

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned November 7, 2026

npx -y skills add nirecom/agents --skill issue-close-migrated --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Issue Close Migrated?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Issue Close Migrated
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/nirecom-issue-close-migrated/badge)](https://www.skillsdirectory.com/skills/nirecom-issue-close-migrated)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: issue-close-migrated
description: Close an issue as status:migrated or status:cancelled with --reason "not planned". Applies label, posts comment, and closes.
user-invocable: false
---

Close issue `<N>` as migrated (merged into another issue) or cancelled.

**Usage:**
- `/issue-close-migrated <N> --type migrated --into <M>` — issue N merged into M
- `/issue-close-migrated <N> --type cancelled` — issue N cancelled

`--into <M>` is **required** for `--type migrated` and **prohibited** for `--type cancelled`.

## Pre-flight

Read `rules/github-issues.md` first — on-demand-only, never auto-injected.

1. Parse `N`, `TYPE`, and (if migrated) `INTO` from the invocation arguments.
2. Verify issue `N` is OPEN: `gh issue view N --json state --jq .state`. Not OPEN → report and exit 0.
3. For `--type migrated`: verify issue `INTO` is OPEN. Not OPEN → report and exit 0.

Run: `bash "$AGENTS_MAIN_ROOT/skills/issue-close-migrated/scripts/pre-flight.sh" "$N" "$TYPE" "$INTO" || { echo "Pre-flight failed — check issue state"; exit 0; }`

## Procedure

Run `bin/github-issues/close-not-planned.sh` as one standalone call: `bash "$AGENTS_MAIN_ROOT/bin/github-issues/close-not-planned.sh" --type "<TYPE>" "<N>"`.
Only when `<TYPE>` is `migrated`, write `--into <INTO>` into the argument list yourself, before `<N>` — do not build that argument with a shell conditional.

The `gh issue close` inside `close-not-planned.sh` is a subprocess of the Bash tool command — `enforce-issue-close.js` (PreToolUse) fires only on the Bash tool command head, not on subprocess calls. No bypass marker is required.

## Rules

- Always close with `--reason "not planned"` via `close-not-planned.sh`. Never use `--reason completed` for migrated or cancelled issues.
- Never invoke `gh issue close` directly from this skill — use `close-not-planned.sh`.

Files in this skill

  • SKILL.md1.8 KB
  • scripts/pre-flight.sh829 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in tools →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.