json - Jenkins get last but one build status -


i can last build (successful/failed) json api of jenkins mentioned in below stack overflow link,

jenkins - last completed build status

my question is, how can last 1 build status?? please let me know if there way achieve this.

my ultimate aim build status of previous build status in loop until particular date reached.

you know current build number, during job. it's $build_number. found under "number": if using /lastbuild/api/json.

subtract 1 that, , that's previous build (unless plugins mess build number sequentiality). use /build_number/api/json, replace build_number 1 calculated


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -