[skip ci] remove deprecated funtions
This commit is contained in:
parent
1ebc1ee98d
commit
65669ee185
2 changed files with 0 additions and 33 deletions
|
@ -82,15 +82,6 @@ open class Prov protected constructor(
|
|||
return evaluate(ResultMode.ALL, name) { task() }
|
||||
}
|
||||
|
||||
/**
|
||||
* defines a task with default success behavior, i.e. returns success if all subtasks finished with success.
|
||||
* Same as requireAll.
|
||||
*/
|
||||
@Deprecated("Use function task instead", replaceWith = ReplaceWith("task()"))
|
||||
fun def(a: Prov.() -> ProvResult): ProvResult {
|
||||
return evaluate(ResultMode.ALL) { a() }
|
||||
}
|
||||
|
||||
/**
|
||||
* defines a task, which returns the returned result, the results of sub-tasks are not considered
|
||||
*/
|
||||
|
@ -105,14 +96,6 @@ open class Prov protected constructor(
|
|||
return evaluate(ResultMode.OPTIONAL) { a() }
|
||||
}
|
||||
|
||||
/**
|
||||
* defines a task, which returns success if all subtasks finished with success
|
||||
*/
|
||||
@Deprecated("Use function task instead", replaceWith = ReplaceWith("task()"))
|
||||
fun requireAll(a: Prov.() -> ProvResult): ProvResult {
|
||||
return evaluate(ResultMode.ALL) { a() }
|
||||
}
|
||||
|
||||
/**
|
||||
* defines a task, which exits the overall execution on failure
|
||||
*/
|
||||
|
|
|
@ -6,14 +6,6 @@ import java.io.File
|
|||
import java.util.*
|
||||
|
||||
|
||||
/**
|
||||
* Returns true if the given file exists.
|
||||
*/
|
||||
@Deprecated("Use checkFile", replaceWith = ReplaceWith("checkFile(file)"))
|
||||
fun Prov.fileExists(file: String, sudo: Boolean = false): Boolean {
|
||||
return cmdNoEval(prefixWithSudo("test -e " + file, sudo)).success
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if the given file exists.
|
||||
*/
|
||||
|
@ -288,14 +280,6 @@ fun Prov.checkDir(dir: String, path: String? = null, sudo: Boolean = false): Boo
|
|||
return cmdNoEval(if (sudo) cmd.sudoizeCommand() else cmd).success
|
||||
}
|
||||
|
||||
@Deprecated("Use checkDir instead.", replaceWith = ReplaceWith("checkDir(dir)"))
|
||||
fun Prov.dirExists(dir: String, path: String? = null, sudo: Boolean = false): Boolean {
|
||||
val effectivePath = if (path != null) path else
|
||||
(if (dir.startsWith(File.separator)) File.separator else "~" + File.separator)
|
||||
val cmd = "cd $effectivePath && test -d $dir"
|
||||
return cmdNoEval(if (sudo) cmd.sudoizeCommand() else cmd).success
|
||||
}
|
||||
|
||||
|
||||
fun Prov.createDir(
|
||||
dir: String,
|
||||
|
|
Loading…
Reference in a new issue