Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Looking for a date field to be the value of another date field plus 1 year

Maggie Stearns
Contributor
January 11, 2017

I have a date picker field. I would like to use scriprunner to help me enable a second field to display the date of the first field plus 1 year. Can you show me how to do that? Thanks

1 answer

1 vote
Deleted user
June 1, 2015

I have implemented this in 2 different ways (my 2nd option is what you want but take a look at my 1st option)

1) Use SCM Polling: This is ideal for a repository with a large user base where doing continuous builds is a nightmare. (My team host 4200~ SVN/GIT repos combined and one specific repo have 1,800 developers on it). We have setup a build time every 3:00pm where all tickets with "custom field Build Request = Yes" will be included in the build.

2) Use a Post Function Script - I have setup a project with a post-function that will run a script (I used groovy) that will POST to the Jenkins URL. My Jenkins project is using buildToken for authentication. You can also use shell script if you want, just curl POST to the jenkins URL then you are good to go.

Both of these assuming that your SVN/GIT Repository is integrated with JIRA and your Jenkins instance has the JIRA Plugin installed.

Suggest an answer

Log in or Sign up to answer