Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Weird to call these one liners, they're just invocation commands.

By that logic, apache is a one-liner.



With that logic there are no one-liners. Even binary code is just an abstraction interpreted by microcode.

The point is that there is a working http server already installed on your machine. And you just need to run this one simple, memorable command to use it.

Very useful if you just want to quickly copy some files from A to B in your LAN or WAN (wouldn't use it over Internet because not encrypted).


Apache requires configuration. The point of those is that they're opening ad hoc an HTTP server without requiring any configuration.

Edit: Someone has posted an Apache example: https://gist.github.com/willurd/5720255#gistcomment-3050599


apache requires a config file. I guess you could put any relevant config into a single line and pipe that through somehow, but it would be a lot more than a single command to define a directory and a port to serve.


PHP was on the list. It also takes a config file (less relavent though to this use)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: