|
|
@ -9,12 +9,12 @@ var uninstallCmd = &cobra.Command{
|
|
|
|
Use: "uninstall",
|
|
|
|
Use: "uninstall",
|
|
|
|
Short: "Uninstall restic and autorestic",
|
|
|
|
Short: "Uninstall restic and autorestic",
|
|
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
|
|
noRestic, _ := cmd.Flags().GetBool("no-restic")
|
|
|
|
restic, _ := cmd.Flags().GetBool("restic")
|
|
|
|
bins.Uninstall(!noRestic)
|
|
|
|
bins.Uninstall(restic)
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
func init() {
|
|
|
|
func init() {
|
|
|
|
rootCmd.AddCommand(uninstallCmd)
|
|
|
|
rootCmd.AddCommand(uninstallCmd)
|
|
|
|
uninstallCmd.Flags().Bool("no-restic", false, "do not uninstall restic.")
|
|
|
|
uninstallCmd.Flags().Bool("restic", false, "also uninstall restic.")
|
|
|
|
}
|
|
|
|
}
|
|
|
|