Skip to content

Instantly share code, notes, and snippets.

@simeji
Last active May 13, 2018 11:18
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 simeji/65b2891039c94e70b3138fb2ea078795 to your computer and use it in GitHub Desktop.
Save simeji/65b2891039c94e70b3138fb2ea078795 to your computer and use it in GitHub Desktop.
OneLiners
bash -c 'trap exit INT; while true; do ( echo "HTTP/1.0 200 Ok"; echo; echo "Hello World" ) | nc -l 8080; done'
# http://blog.livedoor.jp/sonots/archives/34703829.html
( echo "HTTP/1.0 200 Ok"; echo; echo "Hello World" ) | nc -l 8080
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment