Skip to content

Commit

Permalink
buildscripts: move the "ext" block out of "common.gradle"
Browse files Browse the repository at this point in the history
  • Loading branch information
stephengold committed May 10, 2024
1 parent b817550 commit 51bcabc
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 18 deletions.
6 changes: 6 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ plugins {
id 'base' // to add a "clean" task to the root project
}

ext {
group = 'com.github.stephengold'
version = '1.0.5-SNAPSHOT'
websiteUrl = 'https://github.com/stephengold/j-ogg-all'
}

subprojects {
apply from: rootProject.file('common.gradle')
}
Expand Down
6 changes: 0 additions & 6 deletions common.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@ apply plugin: 'java-library' // to build a JVM library
apply plugin: 'maven-publish' // to publish artifacts to Maven repositories
apply plugin: 'signing' // to sign artifacts for publication

ext {
group = 'com.github.stephengold'
version = '1.0.5-SNAPSHOT'
websiteUrl = 'https://github.com/stephengold/j-ogg-all'
}

java {
sourceCompatibility = JavaVersion.VERSION_1_7
targetCompatibility = JavaVersion.VERSION_1_8
Expand Down
12 changes: 6 additions & 6 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ publishing {
artifact sourcesJar
artifactId artifact
from components.java
groupId project.ext.group
groupId rootProject.ext.group
pom {
description = 'J-Ogg is a collection of Java libraries for reading Ogg files and decoding different contained formats.'
developers {
Expand All @@ -77,18 +77,18 @@ publishing {
license {
distribution = 'repo'
name = 'Free and commercial use, modification and redistribution with attribution.'
url = project.ext.websiteUrl + '/blob/master/LICENSE'
url = rootProject.ext.websiteUrl + '/blob/master/LICENSE'
}
}
name = project.ext.group + ':' + artifact
name = rootProject.ext.group + ':' + artifact
scm {
connection = 'scm:git:git://github.com/stephengold/j-ogg-all.git'
developerConnection = 'scm:git:ssh://github.com:stephengold/j-ogg-all.git'
url = project.ext.websiteUrl + '/tree/master'
url = rootProject.ext.websiteUrl + '/tree/master'
}
url = project.ext.websiteUrl
url = rootProject.ext.websiteUrl
}
version project.ext.version
version rootProject.ext.version
}
}
// Staging to OSSRH relies on the existence of 2 properties
Expand Down
12 changes: 6 additions & 6 deletions vorbis/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ publishing {
artifact sourcesJar
artifactId artifact
from components.java
groupId project.ext.group
groupId rootProject.ext.group
pom {
description = 'Library for reading Ogg files and decoding the Vorbis audio format.'
developers {
Expand All @@ -71,18 +71,18 @@ publishing {
license {
distribution = 'repo'
name = 'Free and commercial use, modification and redistribution with attribution.'
url = project.ext.websiteUrl + '/blob/master/LICENSE'
url = rootProject.ext.websiteUrl + '/blob/master/LICENSE'
}
}
name = project.ext.group + ':' + artifact
name = rootProject.ext.group + ':' + artifact
scm {
connection = 'scm:git:git://github.com/stephengold/j-ogg-all.git'
developerConnection = 'scm:git:ssh://github.com:stephengold/j-ogg-all.git'
url = project.ext.websiteUrl + '/tree/master'
url = rootProject.ext.websiteUrl + '/tree/master'
}
url = project.ext.websiteUrl
url = rootProject.ext.websiteUrl
}
version project.ext.version
version rootProject.ext.version
}
}
// Staging to OSSRH relies on the existence of 2 properties
Expand Down

0 comments on commit 51bcabc

Please sign in to comment.