All skills

Repository Safety

Delink GitHub

Safely isolate a copied GitHub repository by removing Git history, GitHub workflow metadata, inherited license metadata, stale project names, outside repository links, and author contacts before starting clean local Git history.

What this skill adds

Use this skill when the user explicitly wants to detach, isolate, rename, clean, reinitialize, delink, disconnect, unpublish, or start fresh Git history for a repository copied from another GitHub project.

Safety Rule

  • This workflow is destructive. Before running reset, confirm the user wants to permanently remove existing root .git, root .github, root LICENSE* or COPYING* files, inherited repository metadata, and stale project references. If the user already gave explicit approval in the current request, proceed with the guarded script command.

Workflow

  • Identify the project root. Prefer an explicit absolute path or positional target.
  • Preview the destructive changes:
  • bash
  • python <skill-dir>/scripts/delink.py plan <project-root> --rename-from old-project --rename-to new-project
  • If the plan matches the request, run the reset:
  • bash

Script

  • Use scripts/delink.py for deterministic operations.
  • Commands:
  • plan: print removals, rename variants, license cleanup, metadata rewrites, directory renames, and Git commands that would run.
  • reset: remove root GitHub linkage, purge inherited metadata, optionally rename project references/directories, initialize Git, stage all files, and create an initial commit.
  • Target path:
  • Positional target: python delink.py plan C:\path\to\project

Rename And Isolation Behavior

  • When --rename-from and --rename-to are provided, the script replaces dynamic casing variants:
  • kebab-case: old-project to new-project
  • snake_case: old_project to new_project
  • PascalCase: OldProject to NewProject
  • camelCase: oldProject to newProject
  • UPPER_CASE: OLD_PROJECT to NEW_PROJECT

Default agent prompt

Use $delink-github to safely detach, rename, clean inherited metadata, purge GitHub linkage, and start clean local Git history for this repository.