Using bash exit codes in Prolog

Relevant thread: How to get shell echo in Prolog variables

I haven’t gotten around to producing a version using strings, yet.