Note
|
Version 4 of this plugin will only work with Gradle 4 and JDK 8. NOTE: Version 5 of this plugin will only work with Gradle 5 and JDK 8. |
This is an init script plugin to provide special repository settings for project teams or companies. See https://docs.gradle.org/current/userguide/init_scripts.html and http://gradle.org/standardizing-enterprise-builds-with-gradle/. See Initialization Scripts.
To apply this plugin to your configuration, add the following lines to your init script:
initscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.intershop.gradle.repoconfig:repoconfig-gradle-plugin:5.0.0'
}
}
apply plugin: com.intershop.gradle.repoconfig.RepoConfigPlugin
repositoryConfiguration {
// all repos in one
releaseRepo = 'https://repository.host.com/repo/content/group/releasesAll'
snapshotRepo = 'https://repository.host.com/repo/content/group/snapshotsAll'
// or ivy and mvn splitted
ivyReleaseRepo = 'https://repository.host.com/repo/content/group/releasesIVY'
mvnReleaseRepo = 'https://repository.host.com/repo/content/group/releasesMVN'
ivySnapshotRepo = 'https://repository.host.com/repo/content/group/snapshotsIVY'
mvnSnapshotRepo = 'https://repository.host.com/repo/content/group/snapshotsMVN'
// company settings
repoHostList = ['repository.host.com', 'repository.host.de']
corporateName = 'project or company name'
}
This plugin applies the following configurations and properties to all projects with the same init.gradle script.
These Ivy patterns will be applied to all configured Ivy repositories - read, build script and publishing configurations if the name starts with 'intershop'.
-
Ivy pattern
pattern:'[organisation]/[module]/[revision]/[type]s/ivy-[revision].xml'
property:corporateIvyPattern
-
Artifact pattern
pattern:'[organisation]/[module]/[revision]/[ext]s/[artifact]-[type](-[classifier])-[revision].[ext]'
property:corporateArtifactPattern
-
Artifact pattern for ivy files
pattern:'[organisation]/[module]/[revision]/[type]s/ivy-[revision].xml'
property:corporateIvyAsArtifactPattern
Property | Type | Default value | Values | Description |
---|---|---|---|---|
|
|
|
repository URL of a repository group with releases for read access |
|
|
|
|
repository URL of a repository group with snapshots for read access |
|
|
|
|
repository URL of a repository group with IVY releases for read access |
|
|
|
|
repository URL of a repository group with MAVEN releases for read access |
|
|
|
|
repository URL of a repository group with IVY snapshots for read access |
|
|
|
|
repository URL of a repository group with MAVEN snapshots for read access |
|
|
|
|
list of allowed repository hosts. Repositories with other host names in build scripts will be dropped |
|
|
|
|
this property is used in information output |
|
|
|
|
repository URL of a repository or repository group with Maven artifacts. This can be used for a public Maven repository. The host of this repository is added to the list of allowed hosts automatically. |
|
|
|
|
If this value is true, JCenter will be added to the list of repsoitories. The host of this repository is added to the list of allowed hosts automatically. |
For local publishing it is necessary to configure a local repository. Therefore it is necessary to specify a path.
System Variable | Java System Variable | Default Value |
---|---|---|
|
|
|
If repositories are secured with username and password, it is necessary to specify these credentials.
System Variable | Java System Variable | Default Value |
---|---|---|
|
|
'' |
|
|
'' |
For special use cases it is necessary to enable or disable special sets of repositories or special repository configurations.
System Variable | Java System Variable | Default Value | Description |
---|---|---|---|
|
|
|
If true, all default settings are disabled. |
|
|
|
If true, snapshot repositories ( |
|
|
|
If true, repositories from |
|
|
|
If true, default configuration for local repository is disabled. |
Copyright 2014-2016 Intershop Communications.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.