How to get exit code of previous command in Bash

he special variable “$?” returns the exit code of last executed command in Bash shell script. Read Full Article.

Leave a Comment