title: Execute npm install in Jenkins only if the package.json has changes
body: <p>I am building(mvn) my project using Jenkins. Jenkins configured to run <code>npm install</code> and <code>bower install</code>. So each and every time when I build my project, the <code>npm install</code> will run, so the build time is more every time. So I thought to run <code>npm install</code> only if there is any changes, like new package is added, version changes or anything got removed etc., in package.json. 
  I googled a lot to find out a way to achieve this, but failed.</p>
  
  <p>Is there any plugins which I can use to achieve this?</p>
  
  <p>Can anyone help me to find out a way to do this?</p>
  
  <p>Thanks in advance.</p>