@@ 3,17 3,14 @@ package main
import (
"os"
"time"
+ "os/exec"
libui "git.sr.ht/~sircmpwn/aerc/lib/ui"
)
+const proxyDisplay = "wlhax-0"
+
func main() {
- var proxyDisplay string
- if len(os.Args) > 1 {
- proxyDisplay = os.Args[1]
- } else {
- proxyDisplay = "wlhax-0"
- }
remoteDisplay, ok := os.LookupEnv("WAYLAND_DISPLAY")
if !ok {
panic("No WAYLAND_DISPLAY set")
@@ 28,6 25,11 @@ func main() {
dash := NewDashboard(proxy)
+ if len(os.Args) > 1 {
+ cmd := exec.Command(os.Args[1], os.Args[2:]...)
+ cmd.Start()
+ }
+
ui, err := libui.Initialize(dash)
if err != nil {
panic(err)