Skip to content

Commit

Permalink
Fix additional buttons commands.
Browse files Browse the repository at this point in the history
  • Loading branch information
71 committed Apr 10, 2020
1 parent fbc8af0 commit 2f840e4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,10 @@ func runButtonPress(pressed bool, ifPressed, ifReleased string) error {
func runCommand(cmd string) error {
command := exec.Command(*shell, "/C", cmd)

if err := command.Start(); err != nil {
return err
}

go func() {
err := command.Wait()

Expand All @@ -113,5 +117,5 @@ func runCommand(cmd string) error {
}
}()

return command.Start()
return nil
}

0 comments on commit 2f840e4

Please sign in to comment.