Files
iris-context/commands/ops/nvm.go
T
VERSE 2ef3c90819 feat(commands): more commands (#30)
- I wrote a scripts to copy and generate all commands missing in iris
from fig repo: https://github.com/withfig/autocomplete
- Add a new script to generate commands docs about which commands
currently are inside commands folder
377d4aac663590e504fe39a92eb4dac4cbd333b2
- Add more icons e64d4e70a1db61e62053460a882e093bd6373ab1
2026-07-04 22:08:36 +07:00

43 lines
2.4 KiB
Go

package ops
import (
"github.com/versenilvis/iris/commands/core"
)
func init() {
core.Register(&core.Spec{
Name: "nvm",
Description: "Node version",
Subcommands: []core.Subcommand{
{Name: "uninstall", Description: "Uninstall a version"},
{Name: "use", Description: "Modify PATH to use <version>. Uses .nvmrc if available and version is omitted"},
{Name: "exec", Description: "Run <command> on <version>. Uses .nvmrc if available and version is omitted"},
{Name: "current", Description: "Display currently activated version of Node"},
{Name: "ls", Description: "List installed versions, matching a given <version> if provided"},
{Name: "version", Description: "Resolve the given description to a single local version"},
{Name: "version-remote", Description: "Resolve the given description to a single remote version"},
{Name: "deactivate", Description: "Undo effects of `nvm` on current shell"},
{Name: "pattern or name", Description: "Pattern or name"},
{Name: "unalias", Description: "Deletes the alias named <name>"},
{Name: "install-latest-npm", Description: "Attempt to upgrade to the latest working `npm` on the current node version"},
{Name: "reinstall-packages", Description: "Reinstall global `npm` packages contained in <version> to current version"},
{Name: "unload", Description: "Unload `nvm` from shell"},
{Name: "dir", Description: "Display path to the cache directory for nvm"},
{Name: "clear", Description: "Empty cache directory for nvm"},
},
Options: []core.Option{
{Name: "--no-colors", Description: "Suppress colored output"},
{Name: "--no-alias", Description: "Suppress `nvm alias` output"},
{Name: "--silent", Description: "Silences stdout/stderr output"},
{Name: "--lts", Description: "Uses automatic LTS (long-term support) alias `lts/*`, if available"},
{Name: "-s", Description: "Skip binary download, install from source only"},
{Name: "--reinstall-packages-from", Description: "When installing, reinstall packages installed in <version>"},
{Name: "--skip-default-packages", Description: "When installing, skip the default-packages file if it exists"},
{Name: "--latest-npm", Description: "Disable the progress bar on any downloads"},
{Name: "--alias", Description: "Uninstall a version"},
{Name: "--help", Description: "Show help page"},
{Name: "--version", Description: "Print out the installed version of nvm"},
},
})
}