get computer's ipv4 address.
npm install ipaddripaddr
===
ipaddr is a command line tool that can let you know your computer's ipv4 address very easy.
Just text ip and press enter in your command line, then you can see your ipv4 address below.
Just text npm install -g ipaddr and press enter in your command line, then wait for a moment, and it's done.
The code of ipaddr is at github.