In Visual Studio 2015, using bower, my package restores fail when behind a firewall with an error similar to:
ECMDERR Failed to exec
The easiest answer which definitely works is here. I had a big headache with this issue. Just download git and install it. While installing choose this option. Run Git from the windows command prompt