Skip to content

Instantly share code, notes, and snippets.

@stfnhh
Last active April 27, 2016 13:21
Show Gist options
  • Save stfnhh/6453887 to your computer and use it in GitHub Desktop.
Save stfnhh/6453887 to your computer and use it in GitHub Desktop.
Creates a simple httpd server in your current directory
#!/bin/bash
P=5000;
if [ -n "$1" ]; then
P=$1
fi
ruby -run -e httpd . -p $P;
@stfnhh
Copy link
Author

stfnhh commented Sep 5, 2013

Install:
sudo curl -s https://gist.github.com/stfnhrrs/6453887/raw/6a3eb1f11d97e95fc01e1b571df6ea7f8d6fa40b/Simple+Server > /usr/local/bin/ss && chmod +x /usr/local/bin/ss

Usage:
ss PORT

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment