Skip to content

Instantly share code, notes, and snippets.

@jamesgecko
Created November 4, 2014 20:36
Show Gist options
  • Select an option

  • Save jamesgecko/cd635ea3cac3c31642da to your computer and use it in GitHub Desktop.

Select an option

Save jamesgecko/cd635ea3cac3c31642da to your computer and use it in GitHub Desktop.
Get my current development url on OS X
#!/bin/sh
interface=$(route get 0.0.0.0 2>/dev/null | awk '/interface: / {print $2}')
domain="http://$(ipconfig getifaddr $interface):3000"
echo $domain
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment