Execute a specific script and stop at the first [e]rror

bash

  • Bourne-Again SHell, an `sh`-compatible command-line interpreter.
    See also: `zsh`, `histexpand` (history expansion).
    More information: <https://gnu.org/software/bash/>.
  • Trick copyright: tl;dr; <https://github.com/tldr-pages/tldr>

bash -e {{path/to/script.sh}}

click the source code to copy install bash on any operating system with command-not-found.com