← Back to Pull requests

fix(add): stop add -g re-adds from removing other global packages #2025

Closed
unknown closed this pull request without merging on Dec 03, 2026 01:35 UTC
View on GitHub
unknown unknown commented on Dec 03, 2026 00:27 UTC
Author

aube add -g semver which put both packages into one shared install, so a later aube add -g semver replaced that install and silently deleted which and its bin. aube remove -g semver took which with it too.

add -g now follows pnpm: each space-separated package gets its own isolated install, and a comma-separated list opts into a shared one.

aube add -g semver which     # two installs; re-adding or removing one leaves the other
aube add -g eslint,prettier  # one shared install, replaced and removed together

Replacing or removing a shared install no longer happens silently:

  • When add -g replaces a shared install and drops packages that were not part of the command, it warns with WARN_AUBE_GLOBAL_GROUP_MEMBERS_REMOVED, naming them and giving the command to reinstall them.

  • remove -g lists every package removed along with the named one. Naming two members of the same install no longer reports the second as "Not globally installed".
  • Existing installs: packages that an older aube bundled from a space-separated command are still bundled. Running add -g again with all of them splits them. Re-adding only one still removes the others, now with the warning above.

    Behavior changes: comma-separated arguments were previously rejected as invalid package names. A comma that follows a path, URL, or git # ref stays part of that argument, so such a spec goes last in a comma-separated list. Space-separated packages are installed one after another, so if one fails, the ones before it stay installed. Because they no longer share a dependency tree, packages that need each other as peers should be passed comma-separated.

    aube update --help also described -g as "Parsed for pnpm compatibility"; it now says that it updates global packages.

    Verified with unit tests for argument grouping and test/global_install.bats (34 passing), including new cases for separate installs, shared-install replacement and removal, and splitting a shared install.

    Fixes #2024

    AI-assisted — Tool: Claude Code; model: anthropic/claude-sonnet-5-5; version: unavailable.

    🤖 Generated with Claude Code

    <!-- This is an auto-generated comment: release notes by coderabbit.ai -->
    <!-- coderabbit-ai-generated:v1 -->

    Summary by CodeRabbit

    New Features
    Global packages installed as separate arguments get isolated installs; comma-separated packages share one install.
    Replacing or removing a shared install affects the entire group. A warning identifies omitted packages and binaries and provides a reinstall command.
    Removing one package from a shared install reports the other affected packages.
    update -g updates all global packages by default, or only the named packages.
    Documentation
    * Clarified global install, update, and removal behavior in CLI help and the package manager guide, including how commas in package specifications are handled.
    <!-- end of auto-generated comment: release notes by coderabbit.ai -->

    Diff: 378 lines (+283 / -95) across 4 files Reviewer: jdx Review duration: 67m
    All Vouch review confidence checks passed
    Residual risk 0.19 = Change Risk (0.43) × (1 − Review Confidence (0.57)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.43 · 378 lines diff across 4 files
    0.43
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    56%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.355
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #2025"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 56.8% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 42.9% (MEDIUM) · Higher = larger blast radius
    42.9%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 56.8% · Lower = rushed or shallow review
    56.8%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 18.6% · Safe to merge
    18.6%
    Repository