Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/guysoft/OctoPi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuy Sheffer <guysoft@gmail.com>2018-06-18 16:15:48 +0300
committerGitHub <noreply@github.com>2018-06-18 16:15:48 +0300
commitf422f1dfa65a10e8c32e262bb302cf336e47bf1d (patch)
treed1744f89094446c6410d456f251a375203c68dee
parent691f4b0eae4ee4f33f416a792a31d982c410558d (diff)
parentc53220a9b7d4108c74cf073683927a0ab2729645 (diff)
Merge pull request #543 from dadosch/patch-2
Put IPv6 addressess in brackets
-rwxr-xr-xsrc/modules/octopi/filesystem/home/pi/scripts/welcome7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/modules/octopi/filesystem/home/pi/scripts/welcome b/src/modules/octopi/filesystem/home/pi/scripts/welcome
index ec03068..46af434 100755
--- a/src/modules/octopi/filesystem/home/pi/scripts/welcome
+++ b/src/modules/octopi/filesystem/home/pi/scripts/welcome
@@ -16,7 +16,12 @@ do
done
for ip in $_IP;
do
- echo " http://$ip"
+ if [[ $ip =~ .*:.* ]]
+ then
+ echo " http://[$ip]"
+ else
+ echo " http://$ip"
+ fi
done
echo