summaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rwxr-xr-xutil/bin/my-global-ipv4-addr3
1 files changed, 2 insertions, 1 deletions
diff --git a/util/bin/my-global-ipv4-addr b/util/bin/my-global-ipv4-addr
index 305d3f80..71608a8a 100755
--- a/util/bin/my-global-ipv4-addr
+++ b/util/bin/my-global-ipv4-addr
@@ -8,7 +8,8 @@
if test $# = 1; then
has() { type "$1" 1>/dev/null 2>/dev/null; }
parse() {
- sed -rn 's/.*((1?[0-9][0-9]|2[0-5][0-9])\.(1?[0-9][0-9]|2[0-5][0-9])\.(1?[0-9][0-9]|2[0-5][0-9])\.(1?[0-9][0-9]|2[0-5][0-9])).*/\1/p' | grep .
+ sed -n 's/.*\(\(1\?[0-9][0-9]\|2[0-5][0-9]\)\.\(1\?[0-9][0-9]\|2[0-5][0-9]\)\.\(1\?[0-9][0-9]\|2[0-5][0-9]\)\.\(1\?[0-9][0-9]\|2[0-5][0-9]\)\).*/\1/p' |
+ grep .
}
get () {
# TODO get random valid user agent