Skip to content

Commit 2f71d90

Browse files
author
Corbin Davenport
committed
Fix UUID generation
1 parent 603adbb commit 2f71d90

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

install.sh

+7-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,13 @@ _report_bug() {
8787
# Function for Google Analytics
8888
_analytics() {
8989
# Generate random user ID string
90-
UUID=$(uuidgen)
90+
if [ -x "$(command -v uuidgen)" ]; then
91+
UUID=$(uuidgen)
92+
elif [ -f "/proc/sys/kernel/random/uuid" ]; then
93+
UUID=$(cat /proc/sys/kernel/random/uuid)
94+
else
95+
UUID="00000000-0000-0000-0000-000000000000"
96+
fi
9197
# Get exact OS
9298
if [ -d "/mnt/c/Windows" ]; then
9399
REALOS="Windows"

0 commit comments

Comments
 (0)