What is the 'function' keyword used in some bash scripts?

前端 未结 3 953
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-11-28 07:05

For example: Bash-Prog-Intro-HOWTO

function foo() {}

I make search queries in info bash and look in releted chapters of POSIX for

3条回答
  •  借酒劲吻你
    2020-11-28 07:43

    The reserved word function is optional. See the section 'Shell Function Definitions' in the bash man page.

提交回复
热议问题