forked from git-lfs/git-lfs
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommand_uninit.go
More file actions
28 lines (22 loc) · 801 Bytes
/
command_uninit.go
File metadata and controls
28 lines (22 loc) · 801 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package commands
import (
"fmt"
"os"
"github.com/spf13/cobra"
)
// TODO: Remove for Git LFS v2.0 https://github.com/github/git-lfs/issues/839
// uninitCmd removes any configuration and hooks set by Git LFS.
func uninitCommand(cmd *cobra.Command, args []string) {
fmt.Fprintf(os.Stderr, "WARNING: 'git lfs uninit' is deprecated. Use 'git lfs uninstall' now.\n")
uninstallCommand(cmd, args)
}
// uninitHooksCmd removes any hooks created by Git LFS.
func uninitHooksCommand(cmd *cobra.Command, args []string) {
fmt.Fprintf(os.Stderr, "WARNING: 'git lfs uninit' is deprecated. Use 'git lfs uninstall' now.\n")
uninstallHooksCommand(cmd, args)
}
func init() {
RegisterCommand("uninit", uninitCommand, func(cmd *cobra.Command) {
cmd.AddCommand(NewCommand("hooks", uninitHooksCommand))
})
}