1.echo $0 (适用: sh/ksh)
2.ps |grep $$|awk '{print $4}' (ps | awk '$1=='$$'{print $NF}')
3.echo $SHELL (查看用户默认的shell,但不实时shell)
1.echo $0 (适用: sh/ksh)
2.ps |grep $$|awk '{print $4}' (ps | awk '$1=='$$'{print $NF}')
3.echo $SHELL (查看用户默认的shell,但不实时shell)