Skip to content

Commit

Permalink
update snapshot usage doc
Browse files Browse the repository at this point in the history
  • Loading branch information
xvik committed Apr 17, 2024
1 parent c8875e9 commit 2cd5e6a
Showing 1 changed file with 6 additions and 22 deletions.
28 changes: 6 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,36 +93,20 @@ older | [1.2.0](https://github.com/xvik/gradle-pom-plugin/tree/1.2.0)
* Select `Commits` section and click `Get it` on commit you want to use (you may need to wait while version builds if no one requested it before)
or use `master-SNAPSHOT` to use the most recent snapshot

For gradle before 6.0 use `buildscript` block with required commit hash as version:

```groovy
buildscript {
repositories {
maven { url 'https://jitpack.io' }
}
dependencies {
classpath 'ru.vyarus:gradle-pom-plugin:b5a8aee24f'
}
}
apply plugin: 'ru.vyarus.pom'
```

For gradle 6.0 and above:

* Add to `settings.gradle` (top most!) with required commit hash as version:
* Add to `settings.gradle` (top most!) (exact commit hash might be used as version):

```groovy
pluginManagement {
resolutionStrategy {
eachPlugin {
if (requested.id.namespace == 'ru.vyarus.pom') {
useModule('ru.vyarus:gradle-pom-plugin:b5a8aee24f')
if (requested.id.id == 'ru.vyarus.pom') {
useModule('ru.vyarus:gradle-pom-plugin:master-SNAPSHOT')
}
}
}
repositories {
maven { url 'https://jitpack.io' }
gradlePluginPortal()
repositories {
gradlePluginPortal()
maven { url 'https://jitpack.io' }
}
}
```
Expand Down

0 comments on commit 2cd5e6a

Please sign in to comment.