* Per Jessen
Patrick Shanahan wrote:
* Per Jessen
[02-01-16 11:09]: Patrick Shanahan wrote:
following might help :) ::
# <--------- Cool Functions by Crouse--------> # Cool Functions for your .bashrc file.
#myip - finds your current IP if your connected to the internet myip () { lynx -dump -hiddenlinks=ignore -nolist http://checkip.dyndns.org:8245/ | awk '{ print $4 }' | sed '/^$/d; s/^[ ]*//g; s/[ ]*$//g' }
Seems a little complicated to me. Besides who has lynx installed anymore :-)
simple matter to change to w3m :)
The cmdline arguments probably aren't the same, but never mind.
which also requires a browser, w3m/lynx/links/elinks/....
or curl/wget, but no sed'ing and awk'ing.
yes, "w3m -dump http://dns24.ch/checkip" works fine.
Anyway, typically you wouldn't need to know your IP when doing a dyndns update. With dns24 for instance, you just specify "data=client" when you're updating.
right -- (paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri http://en.opensuse.org openSUSE Community Member facebook/ptilopteri http://wahoo.no-ip.org Photo Album: http://wahoo.no-ip.org/gallery2 Registered Linux User #207535 @ http://linuxcounter.net -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org