To download the SOFA Statistics from the server I use the wget command:
wget -c http://sourceforge.net/projects/sofastatistics/files/latest/download?source=dlp
The filename of downloaded file in this case is download?source=files
. If I add the --output-document
option to the command, to rename the output file to sofastatistics-latest.deb
, the format of downloaded file is not recognized by dpkg package.
dpkg-deb: error: `sofastatistics-latest.deb' is not a debian format archive
How to rename correctly the downloaded file with wget?
UPDATE - Jan 08 '15
With the provided link the downloaded file always will be a *.tar.gz one. To get it with the real name just add the --content-disposition
option as this (thanks to @6EQUJ5!):
wget --content-disposition http://sourceforge.net/projects/sofastatistics/files/latest/download?source=dlp
But I needed a *.deb file, so here was right the @creaktive, I had to search for a *.deb file link.
Thanks to all for the answers!
file
say? – Closeup--trust-server-names
is more appropriate for my uses. See also this duplicate SO question and the same question on Unix.SE. – Sharonsharona