diff options
author | Leah Rowe <leah@libreboot.org> | 2025-04-13 03:57:04 +0100 |
---|---|---|
committer | Leah Rowe <leah@libreboot.org> | 2025-04-13 03:57:04 +0100 |
commit | eb9e5d2d5d4cac5d07ab1b8160bcf929020927e3 (patch) | |
tree | 7f4c9de655590bd38f7ed0d48a8bdb6499ae46b8 | |
parent | 3bfdecdc75bbc77f795736ac282f858f2eb7ab94 (diff) |
lib.sh: fix bad eval writing version/versiondate
x_ cannot be used, where output is redirected to a file;
only the convention piping can be used, for errors.
relying on x_ in these cases will cause unpredictable bugs.
Signed-off-by: Leah Rowe <leah@libreboot.org>
-rw-r--r-- | include/lib.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/lib.sh b/include/lib.sh index cb42c3d4..99401259 100644 --- a/include/lib.sh +++ b/include/lib.sh @@ -167,7 +167,7 @@ versiondate_="$versiondate" --pretty='%ct' HEAD)" || versiondate="$versiondate_" for p in version versiondate; do chkvars "$p" - eval "x_ printf \"%s\\n\" \"\$$p\" > .$p" + eval "printf \"%s\\n\" \"\$$p\" > .$p || $err \"can't save $p\"" done relname="$projectname-$version" export LOCALVERSION="-$projectname-${version%%-*}" |