mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Extract path to 'nice' to a constant (IDEA-CR-32701)
This commit is contained in:
+3
-2
@@ -18,7 +18,7 @@ fun setupLowPriorityExecution(commandLine: GeneralCommandLine, executablePath: S
|
||||
commandLine.parametersList.prependAll("/c", "start", "/b", "/low", "/wait", GeneralCommandLine.inescapableQuote(""), executablePath)
|
||||
}
|
||||
else {
|
||||
commandLine.exePath = "/usr/bin/nice"
|
||||
commandLine.exePath = nicePath
|
||||
commandLine.parametersList.prependAll("-n", "10", executablePath)
|
||||
}
|
||||
}
|
||||
@@ -34,4 +34,5 @@ private fun canRunLowPriority(): Boolean {
|
||||
return true
|
||||
}
|
||||
|
||||
private val niceExists by lazy { File("/usr/bin/nice").exists() }
|
||||
private const val nicePath = "/usr/bin/nice"
|
||||
private val niceExists by lazy { File(nicePath).exists() }
|
||||
|
||||
Reference in New Issue
Block a user