fix: all issues by golangci-lint

This commit is contained in:
verse91
2026-05-09 23:49:33 +07:00
parent e587f02798
commit c76541258a
18 changed files with 118 additions and 79 deletions
+2 -1
View File
@@ -1,6 +1,7 @@
package root
import (
"context"
"fmt"
"os"
"os/exec"
@@ -55,7 +56,7 @@ func detectShell() string {
}
func getActiveInnerShell(rootPid int, defaultShell string) string {
cmd := exec.Command("ps", "-e", "-o", "pid,ppid,comm")
cmd := exec.CommandContext(context.Background(), "ps", "-e", "-o", "pid,ppid,comm")
out, err := cmd.Output()
if err != nil {
return defaultShell