Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
alist-org
GitHub Repository: alist-org/alist
Path: blob/main/cmd/stop_windows.go
1541 views
1
//go:build windows
2
3
package cmd
4
5
import (
6
"github.com/spf13/cobra"
7
)
8
9
// StopCmd represents the stop command
10
var StopCmd = &cobra.Command{
11
Use: "stop",
12
Short: "Same as the kill command",
13
Run: func(cmd *cobra.Command, args []string) {
14
stop()
15
},
16
}
17
18
func stop() {
19
kill()
20
}
21
22
func init() {
23
RootCmd.AddCommand(StopCmd)
24
25
// Here you will define your flags and configuration settings.
26
27
// Cobra supports Persistent Flags which will work for this command
28
// and all subcommands, e.g.:
29
// stopCmd.PersistentFlags().String("foo", "", "A help for foo")
30
31
// Cobra supports local flags which will only run when this command
32
// is called directly, e.g.:
33
// stopCmd.Flags().BoolP("toggle", "t", false, "Help message for toggle")
34
}
35
36