Move bash specific code out of commonrc