i3-wallpaper-manager/callback.go
Simon Vieille 3e3f4445a4
Some checks are pending
ci/woodpecker/push/build Pipeline is pending approval
ci/woodpecker/push/test Pipeline is pending approval
fix #1: add cache of latest command to not run wallpaper update when it's already up to date
2024-08-11 19:16:00 +02:00

19 lines
305 B
Go

package main
import (
"os"
"os/exec"
)
func CallbackUpdateWallpapers(callback string, files, screens []string) *exec.Cmd {
args := []string{}
for key, file := range files {
args = append(args, screens[key], file)
}
cmd := exec.Command(callback, args...)
cmd.Env = os.Environ()
return cmd
}