delink-github
Skill1 starsChanged 5 months agoMITView on 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.
In this repository19 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- agy-skill-installerSkill
- apex-bug-hunterSkill
- arsSkill
- browser-triageSkill
- claude-md-initSkill
- gemini-skill-packagerSkill
- gh-readySkill
- indian-legal-verificationSkill
- local-systematic-verification-ocrSkill
- magento-team-leadSkill
- merge-gateSkill
- motioncraftSkill
- pdf-vector-engineSkill
- presscraftSkill
- score2mdSkill
- skill-shipSkill
- wpcraftSkill
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 7 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈7
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Use this skill when the user explicitly wants to detach, isolate, rename, clean, reinitialize, delink, disconnect, unpublish, or start …
- Distinctive: line 23
If the plan matches the request, run the reset:
- Very specific: line 41
Use scripts/delink.py for deterministic operations.
- Very specific: line 65
When --rename-from and --rename-to are provided, the script replaces dynamic casing variants:
- Distinctive: line 98
Do not run this on a parent directory, home directory, drive root, or filesystem root.
- Distinctive: line 99
Do not run this to remove someone else's history unless the user owns the repository or has confirmed authority.
- Very specific: line 100
Do not preserve GitHub Actions, issue templates, or pull request templates.
- Very specific: line 101
Do not silently process only one rename option.
- Distinctive: line 102
If git commit fails because identity is missing, configure git config user.name and git config user.email, then rerun or commit manually.
- Distinctive: line 106
When this skill changes, run:
- Distinctive: line 116
After installing locally, restart Codex so the updated skill metadata loads.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Delink GitHub
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:
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:
python <skill-dir>/scripts/delink.py reset <project-root> --rename-from old-project --rename-to new-project --yes- Verify the result:
git -C <final-project-root> remote -v
git -C <final-project-root> branch --show-current
git -C <final-project-root> log --oneline --max-count=3The remote list should be empty, the branch should be main unless changed with --branch, and the new history should contain only the new local initial commit unless --no-commit was used.
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 - Backward-compatible flag:
python delink.py plan --target C:\path\to\project - Defaults to the current working directory when no target is supplied.
Useful options:
--rename-from <old>: old project name to replace across source, config, and docs.--rename-to <new>: new project name and repository slug source.--branch <name>: initial branch name. Defaults tomain.--message <text>: initial commit message. Defaults toinitial commit.--no-commit: initialize and stage files without creating a commit.--yes: required forreset.
Rename And Isolation Behavior
When --rename-from and --rename-to are provided, the script replaces dynamic casing variants:
- kebab-case:
old-projecttonew-project - snake_case:
old_projecttonew_project - PascalCase:
OldProjecttoNewProject - camelCase:
oldProjecttonewProject - UPPER_CASE:
OLD_PROJECTtoNEW_PROJECT - uppercase compact:
OLDPROJECTtoNEWPROJECT - lowercase compact:
oldprojecttonewproject - spaced words:
old projecttonew project
The script skips lockfiles, dependency folders, generated folders, and binary assets to avoid breaking dependency resolution or media files.
It renames matching internal directories, including Python package folders such as old_project, and renames the root folder when its name matches a derived old-name variant.
License And Metadata Cleanup
The script removes root LICENSE* and COPYING* files. It also strips common inherited license metadata from README.md, setup.py, setup.cfg, pyproject.toml, and package.json, including:
- license badges
- README license sections
- license classifiers
license,license_files, and similar metadata linespackage.jsonlicense fields
It rewrites contact metadata to the local Git identity, falling back to Souvik Dey <imsovikde@gmail.com>, and redirects GitHub repository URLs to:
https://github.com/imsovikde/<new-repo-name>Guardrails
- Do not run this on a parent directory, home directory, drive root, or filesystem root.
- Do not run this to remove someone else's history unless the user owns the repository or has confirmed authority.
- Do not preserve GitHub Actions, issue templates, or pull request templates; the root
.githubdirectory is intentionally removed. - Do not silently process only one rename option;
--rename-fromand--rename-tomust be provided together. - If
git commitfails because identity is missing, configuregit config user.nameandgit config user.email, then rerun or commit manually.
Verification
When this skill changes, run:
python skills/delink-github/scripts/test_delink.py
npm run validate:skills
npm test
npm run build
node bin/souvik-skills.cjs install delink-github --forceAfter installing locally, restart Codex so the updated skill metadata loads.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

