feat: better error handling for sys kill signals

This commit is contained in:
Jagadam Dinesh Reddy authored and GitHub committed 2025-07-22 08:25:21 +02:00
1 parent 21ad653b7e
commit 1582b8b2cd
28 files changed
+876 -361

No files matched your search

+5 -2
View File
@@ -17,9 +17,12 @@ var hashCmd = &cobra.Command{
Short: "Hashes a password",
Long: `Hashes a password using bcrypt algorithm.`,
Args: cobra.ExactArgs(1),
Run: func(_ *cobra.Command, args []string) {
RunE: func(_ *cobra.Command, args []string) error {
pwd, err := users.HashPwd(args[0])
checkErr(err)
if err != nil {
return err
}
fmt.Println(pwd)
return nil
},
}