Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion hack/base.mk
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# renovate: datasource=github-tags depName=golangci/golangci-lint
GOLANGCI_VERSION ?= v2.7.2
GOLANGCI_VERSION ?= v2.8.0
# renovate: datasource=github-tags depName=protocolbuffers/protobuf
PROTOC_VERSION ?= v33.4
TOOLS_BIN := $(shell mkdir -p build/tools && realpath build/tools)
Expand Down
9 changes: 5 additions & 4 deletions internal/clipboard/clipboard_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,11 @@ func TestCopy(t *testing.T) {

for _, tc := range tests {
t.Run(tc.name, func(t *testing.T) {
var opts []command.Option[Options]
opts = append(opts, WithSourceProfile(tc.from))
opts = append(opts, WithTargetProfile(tc.to))
opts = append(opts, WithContentType(tc.target))
opts := []command.Option[Options]{
WithSourceProfile(tc.from),
WithTargetProfile(tc.to),
WithContentType(tc.target),
}

err := Run(opts...)

Expand Down
1 change: 1 addition & 0 deletions internal/flatpak/flatpak.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ func Run(opts ...command.Option[Options]) error {
return fmt.Errorf("flatpak %q is not allowed for profile %q", o.Name, o.Profile)
}

//nolint:prealloc
args := []string{"run", o.Name}
args = append(args, o.ExtraArgs...)

Expand Down
4 changes: 2 additions & 2 deletions internal/profiles/profiles.go
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,8 @@ func createNewDisplay(bin string, ca, cert, key []byte, profile *types.Profile,
"-auth", "/home/xorg-user/.Xserver",
"-verbose", "9",
"--",
strings.TrimPrefix(profile.WindowManager, "exec ")}
strings.TrimPrefix(profile.WindowManager, "exec "),
}
}

server, err := files.ServerCookiePath(profile.Name)
Expand Down Expand Up @@ -529,7 +530,6 @@ func createNewDisplay(bin string, ca, cert, key []byte, profile *types.Profile,
x11Dir = fp
}

//nolint
var paths []string
paths = append(paths, "-v=/etc/localtime:/etc/localtime:ro")
paths = append(paths, fmt.Sprintf("-v=%s:/tmp/.X11-unix:rw", x11Dir))
Expand Down
5 changes: 2 additions & 3 deletions internal/runners/docker/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ import (
"golang.org/x/sys/execabs"
)

var (
runnerBinary = files.ContainerRunnerBinary("docker")
)
var runnerBinary = files.ContainerRunnerBinary("docker")

func Run(ew types.EffectiveWorkload) error {
if err := ew.Validate(); err != nil {
Expand Down Expand Up @@ -346,6 +344,7 @@ func hostDbusParams() []string {
}

func cameraParams() []string {
//nolint:prealloc
params := []string{
"--group-add=video",
}
Expand Down
5 changes: 2 additions & 3 deletions internal/runners/podman/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ import (
"golang.org/x/sys/execabs"
)

var (
runnerBinary = files.ContainerRunnerBinary("podman")
)
var runnerBinary = files.ContainerRunnerBinary("podman")

func Run(ew types.EffectiveWorkload) error {
if err := ew.Validate(); err != nil {
Expand Down Expand Up @@ -322,6 +320,7 @@ func hostDbusParams() []string {
}

func cameraParams() []string {
//nolint:prealloc
params := []string{}

vds, _ := filepath.Glob("/dev/video*")
Expand Down
1 change: 1 addition & 0 deletions internal/runners/util/container/container.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ func ID(bin, name string) (string, bool) {
}

func Exec(bin, id string, ew types.EffectiveWorkload) error {
//nolint:prealloc
args := []string{"exec", "--detach", id, ew.Workload.Command}
args = append(args, ew.Workload.Args...)

Expand Down