小编Ank*_*oel的帖子

为什么我的here-docs(<< - )给我一个语法错误?

methods() {
        cat <<-!
        start
        stop
        restart
        reload
        status
        methods
        !
}
Run Code Online (Sandbox Code Playgroud)

这是正确的我得到错误

syntax error: unexpected end of file
Run Code Online (Sandbox Code Playgroud)

bash operators

3
推荐指数
1
解决办法
100
查看次数

标签 统计

bash ×1

operators ×1