Skip to content

Instantly share code, notes, and snippets.

@dropofwill
Last active August 29, 2015 14:06
Show Gist options
  • Save dropofwill/230e23c7ee57f305d8a9 to your computer and use it in GitHub Desktop.
Save dropofwill/230e23c7ee57f305d8a9 to your computer and use it in GitHub Desktop.
Shell Function for Serving pwd on 0.0.0.0
# usage default port: $ serve
# custom port: $ serve 4000
function serve {
port="${1:-3000}"
ruby -run -e httpd . -p $port
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment