I try to use wget to download this but failed.
https://code.ros.org/trac/wg-ros-pkg/raw-attachment/ticket/5069/rein_cmakelists2.patch
sam@sam:/media/Data/code/ros/recognition/rein$ wget https://code.ros.org/trac/wg-ros-pkg/raw-attachment/ticket/5069/rein_cmakelists2.patch
--2012-10-04 16:29:30-- https://code.ros.org/trac/wg-ros-pkg/raw-attachment/ticket/5069/rein_cmakelists2.patch
Resolving code.ros.org (code.ros.org)... 157.22.19.21
Connecting to code.ros.org (code.ros.org)|157.22.19.21|:443... connected.
HTTP request sent, awaiting response... Read error (Connection reset by peer) in headers.
Retrying.
--2012-10-04 16:29:32-- (try: 2) https://code.ros.org/trac/wg-ros-pkg/raw-attachment/ticket/5069/rein_cmakelists2.patch
sam@sam:/media/Data/code/ros/recognition/rein$
But I can use firefox to download.
How to download this kind of file in wget?
Thank you~
Best Answer
Some websites or servers block
wget
(and similar tools) in order to only allow downloads from a browser. You can trick the website into thinking that you are an actual browser. There are many examples available on google. Here is a particularly complete one taken from askapache. To find alternatives just googlewget pretend browser
.This is one command, though I put it on several lines to increase readability. You can make it an alias to make it easier to use.