Repository navigation
Commit be6505a
authored
feat(global): port global package install support to pacquet (#12638)
Port global package installation from the TypeScript pnpm CLI (pnpm11/) to
the Rust pacquet port: `add -g`, `remove -g`, `update -g`, `outdated -g`, and
a global `list`/`ls`.
- New pacquet-global crate (ports @pnpm/global.packages + the pure helpers of
@pnpm/global.commands): scan/find global package groups, hash-symlink
helpers, createGlobalCacheKey, bin-conflict detection, and the depth-0
list -g tree/json/parseable renderers.
- config: default_pnpm_home_dir (mirrors getDataDir), GLOBAL_LAYOUT_VERSION,
the global dir fields, and checkGlobalBinDir (NO_PATH_ENV /
GLOBAL_BIN_DIR_NOT_IN_PATH / PNPM_DIR_NOT_WRITABLE). Config now derives Clone.
- cmd-shim: remove_bin (ports @pnpm/bins.remover) and an exclude_bins variant
of link_bins_of_packages.
- crypto-hash: create_hex_hash (full hex sha256) backing the cache key.
- cli: per-group isolated installs reusing the install pipeline, the
interactive promptApproveGlobalBuilds flow, -g on add/remove/update, the
outdated -g aggregation, and the new list/ls command (global-only for now).
list without -g and runtime --global remain unsupported. This is the pacquet
(Rust) side of a feature that already exists in the TypeScript CLI.1 parent 3425e80 commit be6505a
41 files changed
Lines changed: 2404 additions & 39 deletions
File tree
- .changeset
- pacquet/crates
- cli
- src
- cli_args
- global
- tests
- cmd-shim/src
- config/src
- global_bin_check
- crypto-hash/src
- global
- src
- cache_key
- list
- package-manager/src/install_package_from_registry
- pnpm11
- bins/remover/src
- global
- commands/src
- packages/src
- installing/commands/src
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| 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 | + | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
50 | 51 | | |
51 | 52 | | |
52 | 53 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| 25 | + | |
25 | 26 | | |
26 | 27 | | |
27 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| 18 | + | |
17 | 19 | | |
18 | 20 | | |
19 | 21 | | |
| |||
53 | 55 | | |
54 | 56 | | |
55 | 57 | | |
| 58 | + | |
56 | 59 | | |
57 | 60 | | |
58 | 61 | | |
| |||
176 | 179 | | |
177 | 180 | | |
178 | 181 | | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
179 | 185 | | |
180 | 186 | | |
181 | 187 | | |
| |||
396 | 402 | | |
397 | 403 | | |
398 | 404 | | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
399 | 419 | | |
400 | 420 | | |
401 | 421 | | |
| |||
406 | 426 | | |
407 | 427 | | |
408 | 428 | | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
409 | 439 | | |
410 | 440 | | |
411 | 441 | | |
| |||
421 | 451 | | |
422 | 452 | | |
423 | 453 | | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
424 | 463 | | |
425 | 464 | | |
426 | 465 | | |
| |||
439 | 478 | | |
440 | 479 | | |
441 | 480 | | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
442 | 485 | | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
443 | 490 | | |
444 | 491 | | |
445 | 492 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
| |||
104 | 105 | | |
105 | 106 | | |
106 | 107 | | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
107 | 113 | | |
108 | 114 | | |
109 | 115 | | |
| |||
175 | 181 | | |
176 | 182 | | |
177 | 183 | | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
178 | 218 | | |
179 | 219 | | |
180 | 220 | | |
181 | 221 | | |
182 | 222 | | |
183 | | - | |
| 223 | + | |
184 | 224 | | |
185 | 225 | | |
186 | 226 | | |
| |||
0 commit comments