mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-10-01 06:21:56 -09:00
utils/brmake: fix shellcheck errors
In utils/brmake line 6:
local found ret start d h m mf
^---^ SC2034: found appears unused. Verify use (or export if used externally).
In utils/brmake line 16:
> >( while read line; do
^--^ SC2162: read without -r will mangle backslashes.
For both, the suggestions from shellcheck can be applied.
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
(cherry picked from commit dc364c6ae6)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This commit is contained in:
committed by
Peter Korsgaard
parent
13702acd00
commit
76f2ec3f3d
@@ -3,7 +3,7 @@
|
|||||||
# License: WTFPL, https://spdx.org/licenses/WTFPL.html
|
# License: WTFPL, https://spdx.org/licenses/WTFPL.html
|
||||||
|
|
||||||
main() {
|
main() {
|
||||||
local found ret start d h m mf
|
local ret start d h m mf
|
||||||
|
|
||||||
if ! which unbuffer >/dev/null 2>&1; then
|
if ! which unbuffer >/dev/null 2>&1; then
|
||||||
printf "you need to install 'unbuffer' (from package expect or expect-dev)\n" >&2
|
printf "you need to install 'unbuffer' (from package expect or expect-dev)\n" >&2
|
||||||
@@ -13,7 +13,7 @@ main() {
|
|||||||
start=${SECONDS}
|
start=${SECONDS}
|
||||||
|
|
||||||
( exec 2>&1; unbuffer make "${@}"; ) \
|
( exec 2>&1; unbuffer make "${@}"; ) \
|
||||||
> >( while read line; do
|
> >( while read -r line; do
|
||||||
printf "%(%Y-%m-%dT%H:%M:%S)T %s\n" -1 "${line}"
|
printf "%(%Y-%m-%dT%H:%M:%S)T %s\n" -1 "${line}"
|
||||||
done \
|
done \
|
||||||
|tee -a br.log \
|
|tee -a br.log \
|
||||||
|
|||||||
Reference in New Issue
Block a user