mirror of
https://github.com/priyanshujain/sanderling.git
synced 2026-10-02 19:17:10 +00:00
Publish pipeline: goreleaser + Maven Central + npm (#1)
* feat(cli): add Version var and version subcommand * build(gradle): introduce uatu.version property for lockstep releases * build(sdk-android): swap GitHub Packages for vanniktech Maven Central plugin * build(spec-api): make package publish-ready for npm * ci(release): add goreleaser config for cross-platform uatu CLI builds * ci: add ci and release GitHub Actions workflows * ci: restrict ci.yml to PR + workflow_dispatch (no direct push to master) * docs(release): add local release targets, env example, and install docs * build(sdk-android): make signAllPublications conditional on signing key * ci(release): stage sidecar JAR at embed path before go build * chore(spec-api): regenerate package-lock for updated package.json * ci: install protoc-gen-go plugins before buf generate * ci: bump Node to 22 (required for --experimental-strip-types)
This commit is contained in:
17 files changed
+556
-37
No files matched your search
@@ -1,9 +1,15 @@
|
||||
import com.vanniktech.maven.publish.AndroidSingleVariantLibrary
|
||||
import com.vanniktech.maven.publish.SonatypeHost
|
||||
|
||||
plugins {
|
||||
id("com.android.library") version "8.11.0"
|
||||
kotlin("android") version "2.1.21"
|
||||
`maven-publish`
|
||||
id("com.vanniktech.maven.publish") version "0.30.0"
|
||||
}
|
||||
|
||||
version = findProperty("uatu.version") as String? ?: "0.0.0-dev"
|
||||
group = "io.github.priyanshujain"
|
||||
|
||||
android {
|
||||
namespace = "dev.uatu.sdk"
|
||||
compileSdk = 35
|
||||
@@ -25,34 +31,61 @@ android {
|
||||
testOptions {
|
||||
unitTests.isReturnDefaultValues = true
|
||||
}
|
||||
|
||||
publishing {
|
||||
singleVariant("release") {
|
||||
withSourcesJar()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
register<MavenPublication>("release") {
|
||||
groupId = "dev.uatu"
|
||||
artifactId = "sdk-android"
|
||||
version = "0.0.1"
|
||||
afterEvaluate {
|
||||
from(components["release"])
|
||||
mavenPublishing {
|
||||
publishToMavenCentral(SonatypeHost.CENTRAL_PORTAL, automaticRelease = true)
|
||||
|
||||
// Sign only when a release-signing key is provided (env or Gradle
|
||||
// property). Unsigned runs are useful for `publishToMavenLocal` dry-runs;
|
||||
// CI always has the key set so the actual Central push is always signed.
|
||||
if (findProperty("signingInMemoryKey") != null) {
|
||||
signAllPublications()
|
||||
}
|
||||
|
||||
configure(
|
||||
AndroidSingleVariantLibrary(
|
||||
variant = "release",
|
||||
sourcesJar = true,
|
||||
publishJavadocJar = true,
|
||||
),
|
||||
)
|
||||
|
||||
coordinates(
|
||||
groupId = "io.github.priyanshujain",
|
||||
artifactId = "sdk-android",
|
||||
version = version.toString(),
|
||||
)
|
||||
|
||||
pom {
|
||||
name.set("uatu sdk-android")
|
||||
description.set(
|
||||
"Android runtime SDK for uatu — a property-based UI fuzzer for mobile apps. " +
|
||||
"Exposes a content-provider accessibility bridge consumed by the uatu CLI at test time.",
|
||||
)
|
||||
url.set("https://github.com/priyanshujain/uatu")
|
||||
|
||||
licenses {
|
||||
license {
|
||||
name.set("Apache License, Version 2.0")
|
||||
url.set("https://www.apache.org/licenses/LICENSE-2.0.txt")
|
||||
distribution.set("repo")
|
||||
}
|
||||
}
|
||||
}
|
||||
repositories {
|
||||
maven {
|
||||
name = "GitHubPackages"
|
||||
url = uri("https://maven.pkg.github.com/priyanshujain/uatu")
|
||||
credentials {
|
||||
username = System.getenv("GH_USERNAME") ?: System.getenv("GITHUB_ACTOR") ?: "priyanshujain"
|
||||
password = System.getenv("GH_TOKEN") ?: System.getenv("GITHUB_TOKEN") ?: ""
|
||||
|
||||
developers {
|
||||
developer {
|
||||
id.set("priyanshujain")
|
||||
name.set("Priyanshu Jain")
|
||||
url.set("https://github.com/priyanshujain")
|
||||
}
|
||||
}
|
||||
|
||||
scm {
|
||||
url.set("https://github.com/priyanshujain/uatu")
|
||||
connection.set("scm:git:git://github.com/priyanshujain/uatu.git")
|
||||
developerConnection.set("scm:git:ssh://[email protected]/priyanshujain/uatu.git")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ android {
|
||||
minSdk = 24
|
||||
targetSdk = 35
|
||||
versionCode = 1
|
||||
versionName = "0.0.1"
|
||||
versionName = findProperty("uatu.version") as String? ?: "0.0.0-dev"
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
|
||||
Reference in new issue
Block a user