apilint release process¶
To release a new version of apilint, do the following:
Create a commit titled “Branch X.Y” and modify the files
apilint/build.gradle
andapilint/Config.java
accordingly. See for example Branch 0.5. Note that it’s not necessary to modifyapilint/Config.java
if there aren’t anyapidoc
changes.Create a git tag with the branch version
$ git tag X.Y
Run tests locally by running
$ ./gradlew build
Publish new version to local repository
$ ./gradlew publishToMavenLocal
Modify
mozilla-central
locally to testapilint
with the new version, addmavenLocal()
to everyrepositories {}
block inside the rootbuild.gradle
, e.g.
diff --git a/build.gradle b/build.gradle
index 813ba09aa3d4b..753fdb8d958a6 100644
--- a/build.gradle
+++ b/build.gradle
@@ -60,6 +60,7 @@ allprojects {
}
repositories {
+ mavenLocal()
gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORIES.each { repository ->
maven {
url repository
@@ -100,6 +101,7 @@ buildDir "${topobjdir}/gradle/build"
buildscript {
repositories {
+ mavenLocal()
gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORIES.each { repository ->
maven {
url repository
@@ -113,7 +115,7 @@ buildscript {
ext.kotlin_version = '1.5.31'
dependencies {
- classpath 'org.mozilla.apilint:apilint:0.5.2'
+ classpath 'org.mozilla.apilint:apilint:0.X.Y'
classpath 'com.android.tools.build:gradle:7.0.3'
classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:0.8.2'
classpath 'org.apache.commons:commons-exec:1.3'
Test integration running
api-lint
, this should always pass with noapi.txt
modifications needed (there could be exceptions, but should be intentional).
$ ./mach lint -l android-api-lint
Push the tag to the remote repository (note, the branch commit is not pushed to the main branch).
$ git push -u origin X.Y
Wait until github automation finishes successfully.
(optional, if there are any
apidoc
changes) ask the Releng team to publish a new apidoc version, the bundle will be present under the github artifacts, e.g. seemaven.zip
in releases/tag/0.5. See also Bug 1727585.Add the
plugins.gradle.org
keys to your.gradle
folder, see publishing_gradle_plugins.html.Publish plugin by running
$ ./gradlew apilint:publishPlugins
Finally, update
mozilla-central
to use the new version, e.g. see this patch.