Git-Based Node Package Install
Use this skill when the main question is "what install packet should we trust, what delivery path fits this dependency, and what should we do next?"
The job is not to dump every syntax variant or treat raw Git installs as normal infrastructure.
The job is to:
- normalize the package-delivery packet already in hand,
- choose one primary delivery mode,
- make durability, auth, and build consequences explicit,
- tailor commands to the package manager actually in use,
- leave a clear exit path when a temporary Git bridge is starting to become permanent.
Read references/intake-packets-and-route-outs.md before handling an unfamiliar delivery packet.
Read references/delivery-decision-matrix.md when deciding between Git, tarball, workspace, or publish-first.
Read references/package-manager-behavior.md for manager-specific caveats.
Read references/private-auth-and-ci.md when CI or private auth is already part of the packet.
When to use this skill
- The user wants to install a Node package from GitHub or another Git host
- The package is unpublished, forked, branch-pinned, tag-pinned, commit-pinned, or private
- The package lives in a monorepo and the user is unsure whether Git install, workspace linking, tarball, or publish-first is the honest answer
- The user asks about
git+ssh, git+https, github:owner/repo, tarball installs, npm pack, or file: / workspace links
- A shared dependency is still being treated like a temporary Git shortcut and someone needs to decide whether that shortcut should continue
When not to use this skill
- The main task is fixing local Git branch/history problems → use
git-workflow
- The main task is creating or operating GitHub repos, packages, or releases at the admin level → use
github-repo-management
- The main task is monorepo/task-runner automation rather than package-delivery choice → use
deployment-automation
- The main task is broader runtime, machine, container, or service setup → use
system-environment-setup
- The user already has a normal registry dependency and only needs an ordinary version bump
Instructions
Step 1: Start from the delivery packet already in hand
Use references/intake-packets-and-route-outs.md.
Normalize the request into one of these packet shapes:
temporary-bridge-packet — unpublished fix, fork, PR branch, or short-lived bridge to unblock work now
shared-bridge-packet — teammates or CI need the bridge too, so branch drift and lockfile stability matter
private-auth-packet — the install path is private and the real risk is credential parity across local and CI
artifact-fallback-packet — raw Git source installs are too brittle, but a full registry workflow is still too heavy
workspace-inner-loop-packet — both the app and package are being developed together locally or inside a monorepo
durable-distribution-packet — the dependency is no longer a one-off bridge and should probably stop behaving like one
Capture the minimum useful frame:
Packet: shared-bridge-packet
Package manager: pnpm
Package state: unpublished fork fix
Audience: CI + teammates
Current ref: feature branch
Main risk: branch drift and auth parity
Rule: start from the packet the user already has. Do not force them through a perfect release-management template before answering.
Step 2: Choose one primary delivery mode
Pick exactly one primary mode:
direct-git-bridge — local-only or clearly temporary bridge from Git
sha-pinned-shared-bridge — Git is still the bridge, but shared reproducibility matters
private-git-auth-path — the short-term answer is still private Git, and the key constraint is auth parity
tarball-or-pack-artifact — package the dependency without relying on raw Git source install behavior
workspace-or-file-link — keep co-development local or monorepo-scoped
publish-first-registry-path — move to a durable distribution channel
Optional: mention one fallback mode, but do not flatten every request into a six-option menu.
Step 3: Classify durability
Use a small durability model:
- Tier 0 — local-only
- Tier 1 — team / CI bridge
- Tier 2 — durable shared package
- Tier 3 — production / release infrastructure
Capture only what changes the decision:
- who consumes it
- whether the ref is floating or fixed
- whether raw source install behavior is acceptable
- whether local and CI already share one auth story
- what the exit path should be if the dependency stays around
If the packet spans multiple tiers, plan for the highest one.
Step 4: Pick the safest mode from the ladder
Use references/delivery-decision-matrix.md.
Default order:
publish-first-registry-path
workspace-or-file-link
sha-pinned-shared-bridge
tarball-or-pack-artifact
direct-git-bridge
Rules:
- prefer SHA pins over floating branches for shared use
- prefer artifact or publish-first when raw Git build/prepare behavior is the risk
- prefer workspace / file when both sides move together locally
- treat private auth as a constraint, not proof that Git is the right long-term channel
Step 5: Tailor commands to the manager in use
Give the narrowest correct syntax only.
Common patterns:
- SHA-pinned bridge:
npm install github:owner/repo#<commit> / pnpm add github:owner/repo#<commit> / yarn add owner/repo#<commit> / bun add github:owner/repo#<commit>
- Git URL forms:
git+https://github.com/owner/repo.git#<commit> or git+ssh://git@github.com/owner/repo.git#<commit>
- Tarball:
npm install https://.../package.tgz (or equivalent for pnpm / Yarn / Bun)
- Local path:
"dep": "file:../relative-path" or the normal workspace flow
If publish-first is the right answer, give the handoff plan before dumping temporary Git syntax.
Step 6: Make auth, build, and reproducibility visible
Every answer must cover:
- chosen ref / artifact / published version strategy
- whether install pulls raw source + lifecycle/build behavior
- local + CI auth story
- deterministic install expectation (
npm ci, frozen lockfile equivalents, pinned ref)
- replacement path once the dependency stops being temporary
Defaults:
- floating branches are convenience shortcuts, not shared infrastructure
- private Git is only as good as the worst environment's auth setup
- tarballs trade Git surprises for artifact ownership
- publish-first is usually the honest answer once the package becomes routine shared infrastructure
Step 7: Route the next owner immediately
This skill owns package-delivery choice, not every downstream task.
Typical route-outs:
git-workflow — fix or shape the underlying branch/history state
github-repo-management — operate repos, packages, releases, or package-host settings
deployment-automation — wire repeatable repo scripts or monorepo automation around the chosen package flow
system-environment-setup — handle machine/runtime/container/service setup once the dependency question is no longer the main blocker
If the user asks “how should we consume this package?” stay here.
If they ask “how do we administer hosting or fix auth at the platform level?” route out.
Step 8: Produce one concise install brief
Return a short operator-style brief with:
- packet
- primary mode
- durability tier
- 1-3 recommended steps
- only the needed commands
- auth / build / reproducibility notes
- exit strategy
- next owner if the work leaves this skill
If the honest answer is “publish this or package it properly,” say that directly.
Output format
Always return a Git package install brief, artifact recommendation brief, or publish-first handoff brief.
Required qualities:
- identify the packet already in hand
- choose one primary delivery mode
- classify durability explicitly
- make auth/build/reproducibility consequences visible
- tailor commands to the package manager actually in use
- leave a clear exit strategy
- route package hosting, repo admin, workflow glue, or environment setup to the right neighboring skill
Examples
Example 1: unpublished fix shared in CI
Input
We need an unpublished fix from a GitHub repo for our npm app. Should we install from the branch or do something safer for CI?
Good output direction
shared-bridge-packet
sha-pinned-shared-bridge
- rejects floating branch use for shared CI
- gives one npm-specific command plus an exit path
Example 2: private package auth trouble
Input
Our package is in a private GitHub repo and pnpm install keeps failing in CI. What path should we take?
Good output direction
private-auth-packet
- chooses
private-git-auth-path or publish-first-registry-path
- clarifies CI credential parity and avoids committed secrets
Example 3: monorepo or durable shared package
Input
The package lives in a monorepo. I use Yarn locally but the rest of the team just needs the package in normal projects. Should we install straight from GitHub?
Good output direction
workspace-inner-loop-packet or durable-distribution-packet
- prefers workspace /
file: for local co-development or publish-first for durable use
- does not oversell raw Git install
Best practices
- Start from the delivery packet already in hand, not from a favorite syntax form.
- Treat Git refs as a bridge, not a default release channel.
- Prefer SHA pins over floating branches whenever a Git dependency will be shared.
- Surface lifecycle/build behavior early; raw Git installs can behave like source packaging, not registry downloads.
- Keep local, team/CI, and durable shared usage clearly separated.
- Treat private-auth pain as a signal to re-evaluate the delivery path, not just patch credentials forever.
- Recommend a durable exit path once the dependency stops being temporary.
- Update compact and discovery surfaces when the front-door wording changes materially.
References
1---2name: npm-git-install3description: Route Node package-delivery ambiguity into one install packet: temporary Git bridge, SHA-pinned shared bridge, private-auth Git path, tarball / `npm pack` artifact, workspace / `file:` inner-loop, or publish-first registry handoff. Use when the user wants to install an npm / pnpm / Yarn / Bun package from a branch, tag, commit, fork, private repo, monorepo package, or unreleased fix, and the real question is which delivery path is safest rather than how Git or package registries work in general. Triggers on: npm install from GitHub, git dependency, github:owner/repo, git+ssh, git+https, private package from repo, install branch vs commit, monorepo package install, npm pack vs git, and should we publish this instead.4---56# Git-Based Node Package Install78Use this skill when the main question is **"what install packet should we trust, what delivery path fits this dependency, and what should we do next?"**910The job is not to dump every syntax variant or treat raw Git installs as normal infrastructure.11The job is to:121. normalize the package-delivery packet already in hand,132. choose one primary delivery mode,143. make durability, auth, and build consequences explicit,154. tailor commands to the package manager actually in use,165. leave a clear exit path when a temporary Git bridge is starting to become permanent.1718Read [references/intake-packets-and-route-outs.md](references/intake-packets-and-route-outs.md) before handling an unfamiliar delivery packet.19Read [references/delivery-decision-matrix.md](references/delivery-decision-matrix.md) when deciding between Git, tarball, workspace, or publish-first.20Read [references/package-manager-behavior.md](references/package-manager-behavior.md) for manager-specific caveats.21Read [references/private-auth-and-ci.md](references/private-auth-and-ci.md) when CI or private auth is already part of the packet.2223## When to use this skill24- The user wants to install a Node package from GitHub or another Git host25- The package is unpublished, forked, branch-pinned, tag-pinned, commit-pinned, or private26- The package lives in a monorepo and the user is unsure whether Git install, workspace linking, tarball, or publish-first is the honest answer27- The user asks about `git+ssh`, `git+https`, `github:owner/repo`, tarball installs, `npm pack`, or `file:` / workspace links28- A shared dependency is still being treated like a temporary Git shortcut and someone needs to decide whether that shortcut should continue2930## When not to use this skill31- **The main task is fixing local Git branch/history problems** → use `git-workflow`32- **The main task is creating or operating GitHub repos, packages, or releases at the admin level** → use `github-repo-management`33- **The main task is monorepo/task-runner automation rather than package-delivery choice** → use `deployment-automation`34- **The main task is broader runtime, machine, container, or service setup** → use `system-environment-setup`35- **The user already has a normal registry dependency and only needs an ordinary version bump**3637## Instructions3839### Step 1: Start from the delivery packet already in hand40Use [references/intake-packets-and-route-outs.md](references/intake-packets-and-route-outs.md).4142Normalize the request into one of these packet shapes:43- `temporary-bridge-packet` — unpublished fix, fork, PR branch, or short-lived bridge to unblock work now44- `shared-bridge-packet` — teammates or CI need the bridge too, so branch drift and lockfile stability matter45- `private-auth-packet` — the install path is private and the real risk is credential parity across local and CI46- `artifact-fallback-packet` — raw Git source installs are too brittle, but a full registry workflow is still too heavy47- `workspace-inner-loop-packet` — both the app and package are being developed together locally or inside a monorepo48- `durable-distribution-packet` — the dependency is no longer a one-off bridge and should probably stop behaving like one4950Capture the minimum useful frame:5152```markdown53Packet: shared-bridge-packet54Package manager: pnpm55Package state: unpublished fork fix56Audience: CI + teammates57Current ref: feature branch58Main risk: branch drift and auth parity59```6061Rule: start from the packet the user already has. Do not force them through a perfect release-management template before answering.6263### Step 2: Choose one primary delivery mode64Pick exactly one primary mode:65- `direct-git-bridge` — local-only or clearly temporary bridge from Git66- `sha-pinned-shared-bridge` — Git is still the bridge, but shared reproducibility matters67- `private-git-auth-path` — the short-term answer is still private Git, and the key constraint is auth parity68- `tarball-or-pack-artifact` — package the dependency without relying on raw Git source install behavior69- `workspace-or-file-link` — keep co-development local or monorepo-scoped70- `publish-first-registry-path` — move to a durable distribution channel7172Optional: mention one fallback mode, but do not flatten every request into a six-option menu.7374### Step 3: Classify durability75Use a small durability model:76- **Tier 0 — local-only**77- **Tier 1 — team / CI bridge**78- **Tier 2 — durable shared package**79- **Tier 3 — production / release infrastructure**8081Capture only what changes the decision:82- who consumes it83- whether the ref is floating or fixed84- whether raw source install behavior is acceptable85- whether local and CI already share one auth story86- what the exit path should be if the dependency stays around8788If the packet spans multiple tiers, plan for the highest one.8990### Step 4: Pick the safest mode from the ladder91Use [references/delivery-decision-matrix.md](references/delivery-decision-matrix.md).9293Default order:941. `publish-first-registry-path`952. `workspace-or-file-link`963. `sha-pinned-shared-bridge`974. `tarball-or-pack-artifact`985. `direct-git-bridge`99100Rules:101- prefer **SHA pins** over floating branches for shared use102- prefer **artifact or publish-first** when raw Git build/prepare behavior is the risk103- prefer **workspace / file** when both sides move together locally104- treat **private auth** as a constraint, not proof that Git is the right long-term channel105106### Step 5: Tailor commands to the manager in use107Give the narrowest correct syntax only.108109Common patterns:110- SHA-pinned bridge: `npm install github:owner/repo#<commit>` / `pnpm add github:owner/repo#<commit>` / `yarn add owner/repo#<commit>` / `bun add github:owner/repo#<commit>`111- Git URL forms: `git+https://github.com/owner/repo.git#<commit>` or `git+ssh://git@github.com/owner/repo.git#<commit>`112- Tarball: `npm install https://.../package.tgz` (or equivalent for pnpm / Yarn / Bun)113- Local path: `"dep": "file:../relative-path"` or the normal workspace flow114115If publish-first is the right answer, give the handoff plan before dumping temporary Git syntax.116117### Step 6: Make auth, build, and reproducibility visible118Every answer must cover:119- chosen ref / artifact / published version strategy120- whether install pulls raw source + lifecycle/build behavior121- local + CI auth story122- deterministic install expectation (`npm ci`, frozen lockfile equivalents, pinned ref)123- replacement path once the dependency stops being temporary124125Defaults:126- floating branches are convenience shortcuts, not shared infrastructure127- private Git is only as good as the worst environment's auth setup128- tarballs trade Git surprises for artifact ownership129- publish-first is usually the honest answer once the package becomes routine shared infrastructure130131### Step 7: Route the next owner immediately132This skill owns package-delivery choice, not every downstream task.133134Typical route-outs:135- `git-workflow` — fix or shape the underlying branch/history state136- `github-repo-management` — operate repos, packages, releases, or package-host settings137- `deployment-automation` — wire repeatable repo scripts or monorepo automation around the chosen package flow138- `system-environment-setup` — handle machine/runtime/container/service setup once the dependency question is no longer the main blocker139140If the user asks “how should we consume this package?” stay here.141If they ask “how do we administer hosting or fix auth at the platform level?” route out.142143### Step 8: Produce one concise install brief144Return a short operator-style brief with:145- packet146- primary mode147- durability tier148- 1-3 recommended steps149- only the needed commands150- auth / build / reproducibility notes151- exit strategy152- next owner if the work leaves this skill153154If the honest answer is “publish this or package it properly,” say that directly.155156## Output format157Always return a **Git package install brief**, **artifact recommendation brief**, or **publish-first handoff brief**.158159Required qualities:160- identify the packet already in hand161- choose one primary delivery mode162- classify durability explicitly163- make auth/build/reproducibility consequences visible164- tailor commands to the package manager actually in use165- leave a clear exit strategy166- route package hosting, repo admin, workflow glue, or environment setup to the right neighboring skill167168## Examples169170### Example 1: unpublished fix shared in CI171**Input**172> We need an unpublished fix from a GitHub repo for our npm app. Should we install from the branch or do something safer for CI?173174**Good output direction**175- `shared-bridge-packet`176- `sha-pinned-shared-bridge`177- rejects floating branch use for shared CI178- gives one npm-specific command plus an exit path179180### Example 2: private package auth trouble181**Input**182> Our package is in a private GitHub repo and pnpm install keeps failing in CI. What path should we take?183184**Good output direction**185- `private-auth-packet`186- chooses `private-git-auth-path` or `publish-first-registry-path`187- clarifies CI credential parity and avoids committed secrets188189### Example 3: monorepo or durable shared package190**Input**191> The package lives in a monorepo. I use Yarn locally but the rest of the team just needs the package in normal projects. Should we install straight from GitHub?192193**Good output direction**194- `workspace-inner-loop-packet` or `durable-distribution-packet`195- prefers workspace / `file:` for local co-development or publish-first for durable use196- does not oversell raw Git install197198## Best practices1991. Start from the delivery packet already in hand, not from a favorite syntax form.2002. Treat Git refs as a bridge, not a default release channel.2013. Prefer SHA pins over floating branches whenever a Git dependency will be shared.2024. Surface lifecycle/build behavior early; raw Git installs can behave like source packaging, not registry downloads.2035. Keep local, team/CI, and durable shared usage clearly separated.2046. Treat private-auth pain as a signal to re-evaluate the delivery path, not just patch credentials forever.2057. Recommend a durable exit path once the dependency stops being temporary.2068. Update compact and discovery surfaces when the front-door wording changes materially.207208## References209- [Intake packets and route-outs](references/intake-packets-and-route-outs.md)210- [Delivery decision matrix](references/delivery-decision-matrix.md)211- [Package-manager behavior](references/package-manager-behavior.md)212- [Private auth and CI notes](references/private-auth-and-ci.md)213- `../git-workflow/SKILL.md`214- `../github-repo-management/SKILL.md`215- `../deployment-automation/SKILL.md`216- `../system-environment-setup/SKILL.md`217- npm package spec: https://docs.npmjs.com/cli/v11/using-npm/package-spec218- npm package.json Git docs: https://docs.npmjs.com/cli/v11/configuring-npm/package-json219- npm pack: https://docs.npmjs.com/cli/v11/commands/npm-pack220- pnpm add: https://pnpm.io/cli/add221- pnpm workspaces: https://pnpm.io/workspaces222- Yarn Git protocol: https://yarnpkg.com/protocol/git223- Yarn workspaces: https://yarnpkg.com/features/workspaces224- Bun add: https://bun.sh/docs/pm/cli/add225- GitHub Packages: https://docs.github.com/en/packages/learn-github-packages/introduction-to-github-packages