feat(cli): add aliases to commands

This commit is contained in:
Patryk Hegenberg 2025-01-23 07:59:26 +01:00
parent 53a50f2be4
commit 70dbc9e062
6 changed files with 20 additions and 27 deletions

View file

@ -12,9 +12,10 @@ import (
)
var installCmd = &cobra.Command{
Use: "install [package_name]",
Short: "Install a package with the specified package manager",
Args: cobra.ExactArgs(1),
Use: "install [package_name]",
Short: "Install a package with the specified package manager",
Args: cobra.ExactArgs(1),
Aliases: []string{"i"},
Run: func(cmd *cobra.Command, args []string) {
packageName := args[0]
managerName, _ := cmd.Flags().GetString("manager")