base-files: upgrade: log with date prefix

And log to stderr

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
This commit is contained in:
Yousong Zhou
2020-11-03 10:20:26 +08:00
parent a47279154e
commit 826bb13742
2 changed files with 2 additions and 2 deletions

View File

@@ -64,7 +64,7 @@ ask_bool() {
} }
v() { v() {
[ -n "$VERBOSE" ] && [ "$VERBOSE" -ge 1 ] && echo "$@" [ -n "$VERBOSE" ] && [ "$VERBOSE" -ge 1 ] && echo "$(date) upgrade: $@" >&2
} }
json_string() { json_string() {

View File

@@ -42,7 +42,7 @@ switch_to_ramfs() {
mtd partx losetup mkfs.ext4 nandwrite flash_erase \ mtd partx losetup mkfs.ext4 nandwrite flash_erase \
ubiupdatevol ubiattach ubiblock ubiformat \ ubiupdatevol ubiattach ubiblock ubiformat \
ubidetach ubirsvol ubirmvol ubimkvol \ ubidetach ubirsvol ubirmvol ubimkvol \
snapshot snapshot_tool \ snapshot snapshot_tool date \
$RAMFS_COPY_BIN $RAMFS_COPY_BIN
do do
local file="$(command -v "$binary" 2>/dev/null)" local file="$(command -v "$binary" 2>/dev/null)"