简体   繁体   English

在Ash和Dash中显示函数定义

[英]Show function definition in Ash and Dash

In bash, you can use type to show the body of a function, as in 在bash中,您可以使用type来显示函数的主体,如

bash-4.3$ myfunc() { echo $@ ;}
bash-4.3$ type myfunc
myfunc is a function
myfunc () 
{ 
    echo $@
}

How can I display a shell function body in Ash and Dash? 如何在Ash和Dash中显示shell函数体?

在破折号等POSIX shell中不可能。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM