All skills
github avatar

/issue-fields-migration

@f7a0d97 official
by githubgithub/awesome-copilot40k stars
5,040

Bulk-migrate metadata to GitHub issue fields from two sources: repo labels (e.g. priority labels to a Priority field) and Project V2 fields. Use when users say "migrate my labels to issue fields", "migrate project fields to issue fields", "convert labels to issue fields", "copy project field values to issue fields", or ask about adopting issue fields. Issue fields are org-level typed metadata (single select, text, number, date) that replace label-based workarounds with structured, searchable, cross-repo fields.

Use this Skill: https://skilld.dev/gh/github/awesome-copilot/issue-fields-migration

This session only. Nothing lands on disk.

referenceslabels-api.md

≈541 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Labels API Reference

Reference for GitHub Labels REST API endpoints used in the label migration flow.

List Labels in a Repository

GET /repos/{owner}/{repo}/labels

Returns all labels defined on a repository. Paginated (max 100 per page).

CLI shortcut:

gh label list -R {owner}/{repo} --limit 1000 --json name,color,description

Response fields: id, node_id, url, name, description, color, default.

List Issues by Label

GET /repos/{owner}/{repo}/issues?labels={label_name}&state=all&per_page=100

Returns issues (and pull requests) matching the label. Filter out PRs by checking pull_request field is absent.

CLI shortcut:

gh issue list -R {owner}/{repo} --label "{label_name}" --state all \
  --json number,title,labels --limit 1000

The gh issue list command automatically excludes PRs.

Pagination: use --limit in CLI or page query param in REST. For repos with >1000 matching issues, use cursor-based pagination via Link headers.

Remove a Label from an Issue

DELETE /repos/{owner}/{repo}/issues/{issue_number}/labels/{label_name}

Removes a single label from an issue. Returns 200 OK with the remaining labels on the issue.

Important: URL-encode label names with spaces or special characters:

  • good first issue → good%20first%20issue
  • bug/critical → bug%2Fcritical

CLI shortcut:

gh api /repos/{owner}/{repo}/issues/{number}/labels/{label_name} -X DELETE

Add a Label to an Issue

POST /repos/{owner}/{repo}/issues/{issue_number}/labels

Body: {"labels": ["label1", "label2"]}

Not typically needed for migration, but useful for rollback scenarios.

Notes

  • Labels are repo-scoped. The same label name can exist independently in different repos.
  • There is no MCP tool for listing repo labels. Use gh label list or the REST API.
  • The MCP tool mcp__github__list_issues supports a labels filter for fetching issues by label.
  • Label names are case-insensitive for matching purposes, but the API preserves the original casing.
  • Maximum labels per issue: no hard limit, but practically dozens.

Source: SKILL.md on GitHub

1 alert16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    The skill provides a secure and structured workflow for migrating GitHub labels and Project V2 fields to Issue Fields. It utilizes the official GitHub CLI and incorporates critical security best practices including human-in-the-loop confirmations, detailed dry-run previews, and conflict resolution strategies. All network activity is restricted to GitHub's official API, and no malicious patterns or obfuscation were detected.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: MEDIUM · 1 issue

  • Runlayer6mo

    2/4 files flagged

  • ZeroLeaks5mo

    1 finding · Score: 69/100

Signed by skilld at f7a0d97. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 17 hours ago.

Activeupdated 7 months ago
  • github
  • github-api
  • issue-fields
  • labels
  • migrations
  • project-management
  • metadata
  • bulk-operations

README badge

README badge for github/awesome-copilot/issue-fields-migration

Bulk-migrates metadata into GitHub org-level issue fields from repo labels or Project V2 fields. Supports mapping labels like `p0`, `p1`, `bug` to structured single-select issue fields, and copying Project field values to org fields, with conflict detection and optional label cleanup.

Generated from the current SKILL.md.

Can this migrate labels from multiple repos at once?
Yes. You specify which repos to migrate from, and the skill will handle label discovery and migration across all of them in a single workflow.
What happens if an issue already has a value in the target issue field?
The skill skips that issue during migration to avoid overwriting existing values.
Does this work with both labels and project fields?
Yes. The skill supports migrating from repo labels to issue fields or from Project V2 fields to org-level issue fields. You specify the source when you start.
What if an issue has multiple labels that map to the same issue field?
The skill detects this conflict and asks you to choose a resolution strategy: use the first match, skip the issue, or decide case by case.
Can the skill remove labels after migrating them to issue fields?
Yes. After setting the issue field values, you can optionally have the skill remove the migrated labels from each issue.

Generated from the current SKILL.md. These answers refresh after source changes.