Extract one package from a pnpm or yarn monorepo into a standalone repository with its full git history preserved via git filter-repo.
Carves a single workspace package out of a pnpm or yarn monorepo into its own git repository, preserving the commit history that touched that package. The result is a fresh repo ready to push to a new origin.
monorepo_dir: absolute path to the source monorepo (must be a clean git tree).package_path: relative path of the package to extract (e.g., packages/parser).target_dir: empty directory where the new repo will be created.git-filter-repo installed (pip install git-filter-repo or brew install git-filter-repo).monorepo_dir is clean: git -C <monorepo_dir> status --porcelain must be empty.<monorepo_dir>/<package_path>/package.json exists; abort otherwise.target_dir: git clone --no-local <monorepo_dir> <target_dir>. The --no-local flag forces full object copy.target_dir run git filter-repo --path <package_path> --path-rename <package_path>/:. This rewrites history so only commits touching the package remain and the package becomes the repo root.git -C <target_dir> remote remove origin (filter-repo strips this anyway, but verify).package.json in the extracted repo and remove workspace-protocol dependencies (workspace:*) — replace with the pinned version from the monorepo's lockfile (pnpm why <dep> or read pnpm-lock.yaml)..gitignore, LICENSE, and README.md if missing in the extracted repo.git -C <target_dir> log --oneline | wc -l and record the surviving commit count.npm install (or pnpm/yarn) inside the new repo to confirm the package builds standalone.A populated directory at target_dir containing the extracted repo with rewritten history. A summary printed to stdout listing surviving commit count, removed workspace:* deps, and any unresolved imports the package made into sibling packages.
Run git -C <target_dir> log --all --oneline -- <some-known-file> and compare against the same query in the monorepo (filtering by package_path); commit counts must match. Run the package's npm test (or pnpm test) inside the new repo — if it depends on a sibling, fail loudly with the missing import path. Diff the extracted package.json against the monorepo's to confirm only workspace:* rewrites changed.
package_path historically: git filter-repo --path-glob may need to run before the rename. Detect via git log --follow on a representative file.target_dir exists and is non-empty rather than overwrite.Other publishers' experience with this skill. Self-rating is blocked.
Ratings are limited to publishers while the registry is small — sign in and publish a public skill to rate.
No ratings yet. Be the first.
Same domains or capabilities as amitte/monorepo-package-extractor.
Headless browser helper — capture_screenshot, capture_element (read-only) plus a guarded run_js that only executes allowlisted snippet ids.
Read-only RubyGems helper — search_gems, get_gem_info, list_versions. Surface for Ruby dependency discovery from an agent.
Read-only crates.io helper — search_crates, get_crate_info, list_versions. Surface for Rust dependency discovery from an agent.
Group a list of commit subjects into Keep-a-Changelog sections (Added, Changed, Fixed, Removed) using Conventional Commits prefixes and content heuristics.
Cross-CI status surface — get_workflow_status, list_runs, get_job_logs across GitHub Actions, CircleCI, and Buildkite. Read-only.
Build a one-page cheatsheet for a CLI tool's 80% case by parsing the output of tool --help and grouping flags by intent.