Term: Add a fallback to ps.
This commit is contained in:
parent
3618a4a107
commit
ec0ed23d11
7
neofetch
7
neofetch
|
@ -1452,10 +1452,15 @@ getterm() {
|
|||
name="${name/*\/}"
|
||||
;;
|
||||
|
||||
*)
|
||||
"Linux")
|
||||
parent="$(grep -F "PPid:" "/proc/${1:-$PPID}/status")"
|
||||
name="$(< "/proc/${parent/PPid:[[:space:]]}/comm")"
|
||||
;;
|
||||
|
||||
*)
|
||||
parent="$(ps -p ${1:-$PPID} -o ppid=)"
|
||||
name="$(ps -p $parent -o comm=)"
|
||||
;;
|
||||
esac
|
||||
|
||||
case "${name// }" in
|
||||
|
|
Reference in New Issue