Revision 9214
Added by Aaron Marcuse-Kubitza about 11 years ago
make.sh | ||
---|---|---|
23 | 23 |
# usage: set_make_vars; to_target cmd... |
24 | 24 |
alias to_target='stdout="$target" to_file ' # last space alias-expands next word |
25 | 25 |
|
26 |
make() { echo_func; limit_stdout=1 self "$@"; }
|
|
26 |
make() { echo_func; cmd_log_fd=1 self "$@"; }
|
|
27 | 27 |
|
28 | 28 |
if false; then ## usage: |
29 | 29 |
inline_make 10<<'EOF' |
Also available in: Unified diff
lib/sh/util.sh: command(): use just one control var $cmd_log_fd instead of three flags (limit_log_fd, limit_stdout, stderr_is_errors) that indicated various common fd configurations. this is much clearer (you state which fd the common uses as its logging fd), more configurable (the logging fd can be any fd, not just 1 or 2), and more automatic (redirecting fd 2 to err_fd happens automatically if it isn't used for logging).