Fix carl9170fw shell scripts for shellcheck errors
authorMario Limonciello <mario.limonciello@amd.com>
Thu, 31 Aug 2023 04:03:33 +0000 (23:03 -0500)
committerChristian Lamparter <chunkeey@gmail.com>
Sat, 16 Sep 2023 20:56:36 +0000 (22:56 +0200)
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
autogen.sh
genapi.sh

index a360065b8b4a467c9c051f75d1ce98b57a6e1677..85f011d7551fb24cf0db5964133f06d5d2c1bb62 100755 (executable)
@@ -24,6 +24,7 @@ case "$1" in
                        exit 1
                fi
 
+               # shellcheck source=/dev/null
                . ./.config
                make
 
@@ -40,7 +41,7 @@ case "$1" in
                fi
 
                install -m 644 carlfw/carl9170.fw \
-                       ../carl9170-$CONFIG_CARL9170FW_RELEASE_VERSION.fw
+                       ../carl9170-"$CONFIG_CARL9170FW_RELEASE_VERSION".fw
                echo "done."
        ;;
 
index 8912cc665ae9e53f4e00246356a136b8bbfe8a08..ae9f330daa07bd728da6a2afde60858400a8c59b 100755 (executable)
--- a/genapi.sh
+++ b/genapi.sh
@@ -3,9 +3,9 @@
 cat <<EOF > include/shared/version.h
 #ifndef __CARL9170_SHARED_VERSION_H
 #define __CARL9170_SHARED_VERSION_H
-#define CARL9170FW_VERSION_YEAR $((100`date +%Y`%100))
-#define CARL9170FW_VERSION_MONTH $((100`date +%m`%100))
-#define CARL9170FW_VERSION_DAY $((100`date +%d`%100))
-#define CARL9170FW_VERSION_GIT "`git describe 2>/dev/null`"
+#define CARL9170FW_VERSION_YEAR $((100$(date +%Y)%100))
+#define CARL9170FW_VERSION_MONTH $((100$(date +%m)%100))
+#define CARL9170FW_VERSION_DAY $((100$(date +%d)%100))
+#define CARL9170FW_VERSION_GIT $(git describe 2>/dev/null)
 #endif /* __CARL9170_SHARED_VERSION_H */
 EOF