Commit 588aeed
fix(yarn): use corepack/npm instead of apt, prevent cmdtest conflict
Problem: yarn update tried to use apt and installed wrong package
- catalog used install_method: "package_manager" with apt: "yarnpkg"
- Ubuntu's "yarn" package is actually "cmdtest" (naming conflict!)
- Installed cmdtest (Python testing tool) instead of yarn
- yarn 1.22.22 (nvm) wasn't updated to 4.10.3
- Wrong approach: should use corepack/npm, not apt
Root cause: apt yarn package naming conflict
- Debian/Ubuntu: package "yarn" → cmdtest (legacy)
- Debian/Ubuntu: package "yarnpkg" → yarn (workaround)
- But catalog said "yarnpkg" and apt installed "cmdtest" anyway
Solution: Use dedicated installer with corepack/npm
Changes:
- catalog/yarn.json: Changed to dedicated_script method
- scripts/install_yarn.sh: New installer using corepack/npm
- Checks if Node.js is nvm-managed (like gem checks rbenv)
- Updates via: corepack prepare yarn@stable --activate
- Fallback: npm install -g yarn@latest
- Removes cmdtest if present (apt conflict cleanup)
Expected workflow:
1. Ensure Node.js is nvm-managed (scripts/install_node.sh reconcile)
2. Update yarn via corepack: scripts/install_yarn.sh update
3. Falls back to npm if corepack unavailable
Manual cleanup required:
sudo apt remove cmdtest python3-cliapp python3-ttystatus python3-zombie-imp
Note: Order in guide.sh:
- Node.js: order 40
- npm: order 141
- pnpm: order 142
- yarn: order 151 (processes after Node.js/npm)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 91cb449 commit 588aeed
2 files changed
Lines changed: 110 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
14 | 14 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
0 commit comments