diff --git a/cmd/cmd.go b/cmd/cmd.go index c940ea8..7b5a390 100644 --- a/cmd/cmd.go +++ b/cmd/cmd.go @@ -10,9 +10,10 @@ import ( ) var RootCmd = &cobra.Command{ - Use: "system_setup_tool", - Short: "Installs packages based on TOML configuration", - Run: tui.Run, + Use: "system_setup_tool", + Short: "Installs packages based on TOML configuration", + Version: "0.4.0", + Run: tui.Run, } func init() { diff --git a/cmd/install_cmd.go b/cmd/install_cmd.go index be9de12..b12d83f 100644 --- a/cmd/install_cmd.go +++ b/cmd/install_cmd.go @@ -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") diff --git a/cmd/search_cmd.go b/cmd/search_cmd.go index ca92f53..7d1dff3 100644 --- a/cmd/search_cmd.go +++ b/cmd/search_cmd.go @@ -13,9 +13,10 @@ import ( ) var searchCmd = &cobra.Command{ - Use: "search [package_name]", - Short: "Search for a package across package managers (will search in os|flatpak|homebrew)", - Args: cobra.ExactArgs(1), + Use: "search [package_name]", + Short: "Search for a package across package managers (will search in os|flatpak|homebrew)", + Args: cobra.ExactArgs(1), + Aliases: []string{"s"}, Run: func(cmd *cobra.Command, args []string) { packageName := args[0] managerName, _ := cmd.Flags().GetString("manager") diff --git a/cmd/update_command.go b/cmd/update_command.go index 14c0621..79e2d09 100644 --- a/cmd/update_command.go +++ b/cmd/update_command.go @@ -12,10 +12,11 @@ import ( ) var updateCmd = &cobra.Command{ - Use: "update [package_name]", - Short: "update a package with the specified package manager.", - Long: "update a package with the specified package manager.\nIf no package specified, all packages for the package manager will be updated", - Args: cobra.ExactArgs(1), + Use: "update [package_name]", + Short: "update a package with the specified package manager.", + Long: "update a package with the specified package manager.\nIf no package specified, all packages for the package manager will be updated", + Args: cobra.ExactArgs(1), + Aliases: []string{"u"}, Run: func(cmd *cobra.Command, args []string) { packageName := args[0] managerName, _ := cmd.Flags().GetString("manager") diff --git a/config.toml b/config.toml index 9d94c2c..6dd18cd 100644 --- a/config.toml +++ b/config.toml @@ -101,8 +101,6 @@ packages = [ 'hyprutils', 'kitty', 'mako', - 'SwayNotificationCenter', - 'SwayNotificationCenter-zsh-completion', 'mpv', 'pidgin', 'remmina', @@ -110,7 +108,6 @@ packages = [ 'virt-manager', 'vlc', 'waybar', - 'nwg-panel', 'nwg-look', 'xdg-desktop-portal-hyprland', 'zathura', diff --git a/magefile.go b/magefile.go index eb85b08..b0be26b 100644 --- a/magefile.go +++ b/magefile.go @@ -16,9 +16,8 @@ import ( // A build step that requires additional params, or platform specific steps for example func Build() error { - mg.Deps(InstallDeps) fmt.Println("Building...") - cmd := exec.Command("go", "build", "-o", "system_setup_tool", ".") + cmd := exec.Command("go", "build", "-o", "sst", ".") return cmd.Run() } @@ -26,20 +25,13 @@ func Build() error { func Install() error { mg.Deps(Build) fmt.Println("Installing...") - return os.Rename("./system_setup_tool", "/usr/bin/system_setup_tool") -} - -// Manage your deps, or running package managers. -func InstallDeps() error { - fmt.Println("Installing Deps...") - cmd := exec.Command("go", "get", "github.com/stretchr/piglatin") - return cmd.Run() + return os.Rename("./sst", "~/.local/bin/sst") } // Clean up after yourself func Clean() { fmt.Println("Cleaning...") - os.RemoveAll("MyApp") + os.RemoveAll("system_setup_tool") } // Use gofmt to format your code