Skip to content

Commit

Permalink
fix(cli): inverted boolean flag --no-sound
Browse files Browse the repository at this point in the history
bug from 2c34d12
  • Loading branch information
d3cryptofc committed Sep 26, 2024
1 parent fbf16c1 commit fa13084
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmd/hyprnotify/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,19 @@ import (
)

func main() {
var enableSound bool
var disableSound bool

Cmd := &cobra.Command{
Use: "hyprnotify",
Long: `DBus Implementation of Freedesktop Notification spec for 'hyprctl notify'`,
Run: func(cmd *cobra.Command, args []string) {
internal.InitDBus(enableSound)
internal.InitDBus(!disableSound)
},
}

CmdFlags := Cmd.Flags()

CmdFlags.BoolVarP(&enableSound, "no-sound", "s", false, "disable sound, silent mode")
CmdFlags.BoolVarP(&disableSound, "no-sound", "s", false, "disable sound, silent mode")

Cmd.Execute()
}

0 comments on commit fa13084

Please sign in to comment.