Skip to content

Commit

Permalink
Merge 8987469 into 11403df
Browse files Browse the repository at this point in the history
  • Loading branch information
dconeybe authored Dec 6, 2024
2 parents 11403df + 8987469 commit 75b8206
Showing 1 changed file with 17 additions and 18 deletions.
35 changes: 17 additions & 18 deletions firebase-dataconnect/demo/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,12 @@ spotless {
}
}

@DisableCachingByDefault(because = "Code generation is very fast and not worth caching")
@CacheableTask
abstract class DataConnectGenerateSourcesTask : DefaultTask() {

@get:InputDirectory abstract val inputDirectory: Property<DirectoryTree>
@get:InputDirectory
@get:PathSensitive(PathSensitivity.RELATIVE)
abstract val inputDirectory: Property<DirectoryTree>

@get:Input abstract val firebaseToolsVersion: Property<String>

Expand Down Expand Up @@ -270,22 +272,19 @@ run {

val path = providers.environmentVariable("PATH")
firebaseToolsVersion =
providers.provider {
providers
.exec {
DataConnectGenerateSourcesTask.configureFirebaseCommand(
this,
firebaseCommand = firebaseCommand.get(),
nodeExecutableDirectory = nodeExecutableDirectory.orNull,
path = path.orNull,
)
args("--version")
}
.standardOutput
.asText
.get()
.trim()
}
providers
.exec {
DataConnectGenerateSourcesTask.configureFirebaseCommand(
this,
firebaseCommand = firebaseCommand.get(),
nodeExecutableDirectory = nodeExecutableDirectory.orNull,
path = path.orNull,
)
args("--version")
}
.standardOutput
.asText
.map { it.trim() }

workDirectory = layout.buildDirectory.dir(name)
}
Expand Down

0 comments on commit 75b8206

Please sign in to comment.