Skip to content

Commit

Permalink
Remove deprecated methods from ProguardTask
Browse files Browse the repository at this point in the history
  • Loading branch information
SgtSilvio committed Dec 13, 2024
1 parent cd7e3f5 commit f89e5d0
Showing 1 changed file with 0 additions and 69 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -282,75 +282,6 @@ abstract class ProguardTask : JavaExec() {
action.execute(library)
}

@get:Internal
@get:Deprecated(
"Renamed to reflect that it can contain archive files and/or directories.", ReplaceWith("inputClasspath")
)
val inJars get() = inputClasspath

@get:Internal
@get:Deprecated(
"Renamed to reflect that it can contain archive files and/or directories.", ReplaceWith("outputClasspath")
)
val outJars get() = outputClasspath

@get:Internal
@get:Deprecated(
"Renamed to reflect that it can contain archive files and/or directories.", ReplaceWith("libraryClasspath")
)
val libraryJars get() = libraryClasspath

/**
* Adds input jars with an optional filter.
*
* The order in which the [inJars] and [outJars] methods are called defines the order of the `-injars` and
* `-outjars` arguments.
*/
@Deprecated(
"Inputs and outputs have been refactored to be modifiable whereas this method was add-only.",
ReplaceWith("addInput { classpath.from(files)\nthis.filter.set(filter) }")
)
fun inJars(files: Any, filter: String = "") {
if (inputOutputGroups.last().outputs.isNotEmpty()) {
addInputOutputGroup {}
}
inputOutputGroups.last().addInput {
classpath.from(files)
this.filter.set(filter)
}
}

/**
* Adds an output jar with an optional filter.
*
* The order in which the [inJars] and [outJars] methods are called defines the order of the `-injars` and
* `-outjars` arguments.
*/
@Deprecated(
"Inputs and outputs have been refactored to be modifiable whereas this method was add-only.",
ReplaceWith("addOutput { archiveFile.set(file)\nthis.filter.set(filter) }")
)
fun outJars(file: Any, filter: String = "") {
inputOutputGroups.last().addOutput {
archiveFile.set(project.layout.file(project.files(file).elements.map { it.first().asFile }))
this.filter.set(filter)
}
}

/**
* Adds library jars with an optional filter.
*/
@Deprecated(
"Inputs and outputs have been refactored to be modifiable whereas this method was add-only.",
ReplaceWith("addLibrary { classpath.from(files)\nthis.filter.set(filter) }")
)
fun libraryJars(files: Any, filter: String = "") {
addLibrary {
classpath.from(files)
this.filter.set(filter)
}
}

override fun exec() {
standardOutput = LineOutputStream { logger.info(it) }
errorOutput = LineOutputStream { logger.error(it) }
Expand Down

0 comments on commit f89e5d0

Please sign in to comment.