14 lines
250 B
Bash
Executable File

#!/bin/bash
#mymodel=`cat /sys/firmware/devicetree/base/model 2>/dev/null`
# https://stackoverflow.com/a/46163991
model=""
while IFS= read -r -d '' substring || [[ $substring ]]; do
model+="$substring"
done </proc/device-tree/model
echo $model