This is very useful Ruby command to share your local folder with everyone on the same network.

Thanks to Rohan! As we were working on something and he wanted me to share my local folder quickly.

Rohan shared this Ruby command with me and since then every now and then I am using it in office to share stuff with teams. Command is:

ruby -rwebrick -e '>PORT_NUMBER,:DocumentRoot=>”DIRECTORY_PATH").start'
  ruby -rwebrick -e '>2121,:DocumentRoot=>”/home/public/picture").start'

PORT_NUMBER - Port to listen a request

DIRECTORY_PATH - Root Path of the server file

Then check your ip address using command

> ifconfig
  inet netmask 0xffffff00 broadcast

Now you are all set and can share url -> http://your_ip_address:PORT_NUMBER

  For above mentioned sample url will be