feat: now pressing space show alias as full command

This commit is contained in:
verse91
2026-04-19 09:55:31 +07:00
parent 3adc045c09
commit 7c11a3a620
3 changed files with 20 additions and 21 deletions
-3
View File
@@ -14,7 +14,6 @@ type procInfo struct {
comm string
}
// detectShell identifies the shell type by scanning parent processes
func detectShell() string {
pid := os.Getppid()
for i := 0; i < 5 && pid > 1; i++ {
@@ -55,8 +54,6 @@ func detectShell() string {
return "bash"
}
// getActiveInnerShell retrieves the most recently started shell in the process tree
// example: getActiveInnerShell(1234, "bash")
func getActiveInnerShell(rootPid int, defaultShell string) string {
cmd := exec.Command("ps", "-e", "-o", "pid,ppid,comm")
out, err := cmd.Output()