更改当前正在运行的脚本的精确级别


11

我想更改当前正在运行的脚本的精确级别:

#!/bin/bash

nice_it ( ) {
    nice
    ps -o "%p %r %y %x %n %c %a"
}

nice_it

这是行不通的,因为nice试图更改由它启动的命令的精确级别。

有可能在bash中实现这一目标吗?

Answers:


By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.