Revised code for our jenkins system