mirror of
https://codeberg.org/libreboot/lbmk.git
synced 2026-07-13 06:49:52 +02:00
Less cat abuse
More than 90% of cats were thus terminated. read (shell built-in) is better at reading, and dogs are better pets. Signed-off-by: Riku Viitanen <riku.viitanen@protonmail.com>
This commit is contained in:
@@ -21,10 +21,10 @@ set -u
|
||||
|
||||
. "include/err.sh"
|
||||
|
||||
project="$(cat projectname)"
|
||||
read project < projectname
|
||||
|
||||
version="version-unknown"
|
||||
[ -f version ] && version="$(cat version)"
|
||||
[ -f version ] && read version < version
|
||||
version_="${version}"
|
||||
if [ -e ".git" ]; then
|
||||
version="$(git describe --tags HEAD 2>&1)" || \
|
||||
@@ -34,7 +34,7 @@ if [ -e ".git" ]; then
|
||||
fi
|
||||
|
||||
versiondate="version-date-unknown"
|
||||
[ -f versiondate ] && versiondate="$(cat versiondate)"
|
||||
[ -f versiondate ] && read versiondate < versiondate
|
||||
versiondate_="${versiondate}"
|
||||
if [ -e ".git" ]; then
|
||||
versiondate="$(git show --no-patch --no-notes --pretty='%ct' HEAD)" || \
|
||||
|
||||
Reference in New Issue
Block a user