.gitlab-ci: Check for shell errors in CI
Recently a shell error snuck into version control and I didn't notice it because it was at the tail end of a short-circuited conditional.
This commit adds a little shell validation to CI to avoid that sort of thing in the future.
Edited by Ray Strode