summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Mubashshir <ahm@jadupc.com>2023-07-27 21:20:05 +0600
committerLibravatar Mubashshir <ahm@jadupc.com>2023-07-27 21:20:05 +0600
commit1dbd7c05a2496a50bcbeaccfb5bcc412a8ef1559 (patch)
tree17d5c5070f1628f6a8e75ec7548319252fa84b14
parentd4a7a2e20dabc3941b73a855b93e2e85c9974cd7 (diff)
downloadpatches-1dbd7c05a2496a50bcbeaccfb5bcc412a8ef1559.tar.gz
patches-1dbd7c05a2496a50bcbeaccfb5bcc412a8ef1559.zip
Add unknown board build number support
Signed-off-by: Mubashshir <ahm@jadupc.com>
-rw-r--r--patch/armbian2shopno8
1 files changed, 6 insertions, 2 deletions
diff --git a/patch/armbian2shopno b/patch/armbian2shopno
index 43caa53..314e3fc 100644
--- a/patch/armbian2shopno
+++ b/patch/armbian2shopno
@@ -1,8 +1,12 @@
#!/bin/sh
VERSION=4.11
BOARD=$(
- xargs -0 printf '%s\n' < /sys/firmware/devicetree/base/model |
- xargs printf '%s\n' | tail -n2 | tr -d '[:space:][:punct:]'
+ if test -e /sys/firmware/devicetree/base/model; then
+ xargs -0 printf '%s\n' < /sys/firmware/devicetree/base/model |
+ xargs printf '%s\n' | tail -n2
+ else
+ echo Generic-$(uname -m)
+ fi | tr -d '[:space:][:punct:]'
)
if [ "$(id -u)" -gt 0 ]; then