Skip to content

Instantly share code, notes, and snippets.

@yoshikaw
Created March 16, 2017 10:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yoshikaw/b404f72d7c8d981ac1e42f8edda023d4 to your computer and use it in GitHub Desktop.
Save yoshikaw/b404f72d7c8d981ac1e42f8edda023d4 to your computer and use it in GitHub Desktop.
p `route print 0.0.0.0`.scan(/(\d+\.\d+\.\d+\.\d+)\s+\d+\n/)[0][0]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment