1
0
mirror of https://github.com/zu1k/nali.git synced 2025-02-02 10:22:41 +08:00
nali/cmd/update.go
zu1k 6bc863cc69 refactor: project structure
Signed-off-by: zu1k <i@lgf.im>
2022-03-02 12:43:41 +08:00

23 lines
381 B
Go

package cmd
import (
"github.com/zu1k/nali/internal/db"
"github.com/spf13/cobra"
)
// updateCmd represents the update command
var updateCmd = &cobra.Command{
Use: "update",
Short: "update chunzhen ip database",
Long: `update chunzhen ip database`,
Run: func(cmd *cobra.Command, args []string) {
db.UpdateAllDB()
},
}
func init() {
rootCmd.AddCommand(updateCmd)
}