diff --git a/main.go b/main.go index 5ac46f2..8fab274 100644 --- a/main.go +++ b/main.go @@ -719,17 +719,24 @@ func main() { fmt.Printf("Couldn't write jfa-go.service: %v\n", err) os.Exit(1) } - fmt.Print(info(`If you want to execute jfa-go with special arguments, re-run this command with them. + fmt.Println(info(`If you want to execute jfa-go with special arguments, re-run this command with them. Move the newly created "jfa-go.service" file to ~/.config/systemd/user (Creating it if necessary). Then run "systemctl --user daemon-reload". You can then run: `)) - color.New(color.FgGreen).PrintFunc()("To start: ") + // I have no idea why sleeps are necessary, but if not the lines print in the wrong order. + time.Sleep(time.Millisecond) + color.New(color.FgGreen).Print("To start: ") + time.Sleep(time.Millisecond) fmt.Print(info("systemctl --user start jfa-go\n\n")) - color.New(color.FgRed).PrintFunc()("To stop: ") + time.Sleep(time.Millisecond) + color.New(color.FgRed).Print("To stop: ") + time.Sleep(time.Millisecond) fmt.Print(info("systemctl --user stop jfa-go\n\n")) - color.New(color.FgYellow).PrintFunc()("To restart: ") + time.Sleep(time.Millisecond) + color.New(color.FgYellow).Print("To restart: ") + time.Sleep(time.Millisecond) fmt.Print(info("systemctl --user stop jfa-go\n")) } else if TRAY { RunTray()