2022-03-25 23:59:01 +00:00
|
|
|
package main
|
|
|
|
|
|
|
|
import (
|
|
|
|
"strings"
|
|
|
|
|
2022-04-06 13:45:46 +00:00
|
|
|
Z "github.com/rwxrob/bonzai/z"
|
2022-04-09 08:50:54 +00:00
|
|
|
"github.com/rwxrob/help"
|
2022-03-25 23:59:01 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
var tmux = &Z.Cmd{
|
|
|
|
Name: `tmux`,
|
|
|
|
Summary: `make tmux updates`,
|
|
|
|
Commands: []*Z.Cmd{help.Cmd, tmuxUpdate},
|
|
|
|
}
|
|
|
|
|
|
|
|
var tmuxUpdate = &Z.Cmd{
|
|
|
|
Name: `update`,
|
|
|
|
Summary: `update the onscreen status`,
|
|
|
|
Call: func(_ *Z.Cmd, args ...string) error {
|
|
|
|
msg := strings.Join(args, " ")
|
|
|
|
return Z.Exec(
|
|
|
|
"tmux", "-L", "live", "set", "-g", "status-right", msg,
|
|
|
|
)
|
|
|
|
},
|
|
|
|
}
|