Description
With nupm loaded, scope modules shows:
╭───┬──────┬────────────────────────┬────────────────┬────────────────┬─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┬──────────────┬─────╮
│ # │ name │ commands │ aliases │ externs │ submodules │ constants │ ... │
├───┼──────┼────────────────────────┼────────────────┼────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┼──────────────┼─────┤
│ 0 │ nupm │ ╭───┬──────┬─────────╮ │ [list 0 items] │ [list 0 items] │ ╭───┬─────────┬───────────────────────────┬────────────────┬────────────────┬────────────────┬────────────────┬───────────────┬─────────────┬─────╮ │ [list 0 │ ... │
│ │ │ │ # │ name │ decl_id │ │ │ │ │ # │ name │ commands │ aliases │ externs │ submodules │ constants │ has_env_block │ description │ ... │ │ items] │ │
│ │ │ ├───┼──────┼─────────┤ │ │ │ ├───┼─────────┼───────────────────────────┼────────────────┼────────────────┼────────────────┼────────────────┼───────────────┼─────────────┼─────┤ │ │ │
│ │ │ │ 0 │ nupm │ 614 │ │ │ │ │ 0 │ install │ ╭───┬─────────┬─────────╮ │ [list 0 items] │ [list 0 items] │ [list 0 items] │ [list 0 items] │ false │ │ ... │ │ │ │
│ │ │ ╰───┴──────┴─────────╯ │ │ │ │ │ │ │ # │ name │ decl_id │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├───┼─────────┼─────────┤ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ 0 │ install │ 625 │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ╰───┴─────────┴─────────╯ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ 1 │ publish │ ╭───┬─────────┬─────────╮ │ [list 0 items] │ [list 0 items] │ [list 0 items] │ [list 0 items] │ false │ │ ... │ │ │ │
│ │ │ │ │ │ │ │ │ │ # │ name │ decl_id │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├───┼─────────┼─────────┤ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ 0 │ publish │ 641 │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ╰───┴─────────┴─────────╯ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ 2 │ search │ ╭───┬────────┬─────────╮ │ [list 0 items] │ [list 0 items] │ [list 0 items] │ [list 0 items] │ false │ │ ... │ │ │ │
│ │ │ │ │ │ │ │ │ │ # │ name │ decl_id │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├───┼────────┼─────────┤ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ 0 │ search │ 647 │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ╰───┴────────┴─────────╯ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ 3 │ status │ ╭───┬────────┬─────────╮ │ [list 0 items] │ [list 0 items] │ [list 0 items] │ [list 0 items] │ false │ │ ... │ │ │ │
│ │ │ │ │ │ │ │ │ │ # │ name │ decl_id │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├───┼────────┼─────────┤ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ 0 │ status │ 648 │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ╰───┴────────┴─────────╯ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ 4 │ test │ ╭───┬──────┬─────────╮ │ [list 0 items] │ [list 0 items] │ [list 0 items] │ [list 0 items] │ false │ │ ... │ │ │ │
│ │ │ │ │ │ │ │ │ │ # │ name │ decl_id │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├───┼──────┼─────────┤ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ 0 │ test │ 649 │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ╰───┴──────┴─────────╯ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ╰───┴─────────┴───────────────────────────┴────────────────┴────────────────┴────────────────┴────────────────┴───────────────┴─────────────┴─────╯ │ │ │
╰───┴──────┴────────────────────────┴────────────────┴────────────────┴─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┴──────────────┴─────╯
Is there any technical reason why these are exported as submodules rather than subcommands?
I'd be happy to submit a PR to restructure if there's no technical reason. There shouldn't be any functional difference; just that scope modules would be a lot cleaner.
Steps to reproduce
scope modules | where name == nupm | wslClip
Version
NUPM version 0.2.0
| key |
value |
| version |
0.98.0 |
| major |
0 |
| minor |
98 |
| patch |
0 |
| branch |
|
| commit_hash |
|
| build_os |
linux-x86_64 |
| build_target |
x86_64-unknown-linux-gnu |
| rust_version |
rustc 1.80.1 (3f5fd8dd4 2024-08-06) |
| rust_channel |
stable-x86_64-unknown-linux-gnu |
| cargo_version |
cargo 1.80.1 (376290515 2024-07-16) |
| build_time |
2024-09-18 16:11:39 -04:00 |
| build_rust_channel |
release |
| allocator |
mimalloc |
| features |
default, sqlite, trash |
| installed_plugins |
nuplugin 0.98.0 |
Description
With
nupmloaded,scope modulesshows:Is there any technical reason why these are exported as submodules rather than subcommands?
I'd be happy to submit a PR to restructure if there's no technical reason. There shouldn't be any functional difference; just that
scope moduleswould be a lot cleaner.Steps to reproduce
Version
NUPM version 0.2.0