Errexit: if a command has an exit status of anything but 0 (zero), execute the err trap (if it is set and exists).
errexit:如果某个命令产生非0(零)的退出状态并且设置了err陷阱,则执行err陷阱并退出。
The ERR goes with the signal list within the trap command. In the following example, a non-existent file is copied, which invokes an error
ERR 在 trap 命令中提供了一个信号列表。
应用推荐