refactor to use a travis_cmd bash function to improve the build script readability