简体   繁体   中英

Refreshing Snapshot Dependencies in Eclipse with Gradle

I'm using the Gradle STS plugin for Eclipse and it works fairly well.

Lately we've begun developing using Snapshots, and new snapshots are often released every hour or so.

When I use the 'Refresh All' option I want it to also call --refresh-dependencies so that new snapshots are resolved and downloaded when available.

Is there a particular hook that can be overridden to ensure that snapshots will be checked every time I call 'Refresh All' or 'Refresh Dependencies'?

I think this is covered in section 51.9.3 of the Gradle User Guide.

You could try:

configurations.MY_CONFIGURATION {
  resolutionStrategy {
    // don't cache changing modules at all
    cacheChangingModulesFor 0, 'seconds'
  }
}

Also see: the ResolutionStrategy docs.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM