Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify access to current project's members #1359

Merged
merged 1 commit into from
Jan 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ repositories {
java.toolchain.languageVersion =
JavaLanguageVersion.of(property("com.ibm.wala.jdk-version") as String)

base.archivesName = "com.ibm.wala${project.path.replace(':', '.')}"
base.archivesName = "com.ibm.wala${path.replace(':', '.')}"

configurations {
resolvable("ecj")
Expand Down Expand Up @@ -135,15 +135,15 @@ tasks.named<Test>("test") {
}
}

if (project.hasProperty("excludeSlowTests")) {
if (hasProperty("excludeSlowTests")) {
dependencies { testImplementation(testFixtures(project(":core"))) }
tasks.named<Test>("test") { useJUnitPlatform { excludeTags("slow") } }
}

val ecjCompileTaskProviders =
sourceSets.map { sourceSet -> JavaCompileUsingEcj.withSourceSet(project, sourceSet) }

project.tasks.named("check") { dependsOn(ecjCompileTaskProviders) }
tasks.named("check") { dependsOn(ecjCompileTaskProviders) }

tasks.withType<JavaCompile>().configureEach {
options.run {
Expand Down Expand Up @@ -172,7 +172,7 @@ tasks.withType<JavaCompileUsingEcj>().configureEach {
// fixtures, we extend the main sourceSet to include all
// test-fixture sources too. This hack is only applied when
// WALA itself is an included build.
if (project.gradle.parent != null) {
if (gradle.parent != null) {
afterEvaluate {
sourceSets["main"].java.srcDirs(sourceSets["testFixtures"].java.srcDirs)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ val mavenPublication =
}

pom {
name = project.properties["POM_NAME"] as String
name = property("POM_NAME") as String
description = "T. J. Watson Libraries for Analysis"
inceptionYear = "2006"
url = "https://github.com/wala/WALA"
Expand Down Expand Up @@ -128,17 +128,17 @@ val mavenRepository: MavenArtifactRepository =
url =
uri(
(if (isSnapshot)
project.properties.getOrDefault(
properties.getOrDefault(
"SNAPSHOT_REPOSITORY_URL",
"https://oss.sonatype.org/content/repositories/snapshots/")
else
project.properties.getOrDefault(
properties.getOrDefault(
"RELEASE_REPOSITORY_URL",
"https://oss.sonatype.org/service/local/staging/deploy/maven2/"))
as String)
credentials {
username = project.properties["SONATYPE_NEXUS_USERNAME"] as String?
password = project.properties["SONATYPE_NEXUS_PASSWORD"] as String?
username = properties["SONATYPE_NEXUS_USERNAME"] as String?
password = properties["SONATYPE_NEXUS_PASSWORD"] as String?
}
}

Expand Down
Loading