bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Bug-wget] Parameter --output-document=file


From: Tony Lewis
Subject: RE: [Bug-wget] Parameter --output-document=file
Date: Wed, 26 Jan 2011 08:25:38 -0800

It sounds like you were depending on a bug in version 1.9, which has since been 
fixed. If you ask wget to retrieve *_20110119_File.csv and put the results into 
File.csv then it's going to do its best to accomplish that task.

You might want to remove the --output-document and use a script that runs after 
wget to select the first file and rename it to File.csv.

Tony
-----Original Message-----
From: address@hidden [mailto:address@hidden On Behalf Of Ong Chun Yun
Sent: Wednesday, January 26, 2011 2:10 AM
To: address@hidden
Subject: [Bug-wget] Parameter --output-document=file

Hi 
 
I encountered some issue with the wget command line due to different versions 
in 
the different environment (DEV,PROD).

In PROD, wget is 1.9.1, and in DEV, wget is 1.12. I am not sure if the 
difference in version is causing my output to be different.

The command line is something like this:
wget ftp://*username*:address@hidden/abc/abc/*_20110119_File.csv 
--tries=3 --waitretry=10 --timeout=60 --output-document=File.csv

In the FTP server, there are 2 files:
123456_20110119_File.csv
345678_20110119_File.csv

These 2 files will be download and concatenated to the output file File.csv in 
DEV (wget 1.12)
However actually these 2 files are not concatenated to the output file File.csv 
in PROD (wget 1.9)

>From the wget document and after much googling, i understand that the actual 
>(or 
latest) behaviour for this parameter is:
‘--output-document=file’file.
The documents will not be written to the appropriate files, but all will be 
concatenated
together and written to 
 
Problem is the the PROD behavior is the 'correct' one for this legacy program. 
And the UNIX administrators will upgrade the wget in PROD to 1.12. This legacy 
program will fail. Unfortunately, my team do not have control/say over the UNIX 
environments.
 
Question - is it possible to configure in the wgetrc to just download the first 
file instead of merging the files into 1 file? Or have it in the parameter? I 
need the output to be File.csv..
 
I am desperate for help, searched high and low on the internet, and tried some 
of the parameters but to no avail. Please help. Thanks





reply via email to

[Prev in Thread] Current Thread [Next in Thread]