add version cmd, fix bug for uninstall cmd

This commit is contained in:
yuzuki999
2023-05-30 04:04:05 +08:00
parent 017af454cb
commit 2bd104e627
4 changed files with 33 additions and 17 deletions

View File

@@ -49,6 +49,7 @@ func uninstallHandle(_ *cobra.Command, _ []string) {
_ = os.RemoveAll("/etc/systemd/system/V2bX.service")
_ = os.RemoveAll("/etc/V2bX/")
_ = os.RemoveAll("/usr/local/V2bX/")
_ = os.RemoveAll("/bin/V2bX")
_, err = execCommand("systemctl daemon-reload&&systemctl reset-failed")
if err != nil {
fmt.Println(Err("exec cmd error: ", err))