[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-wget] [PATCH] New option: --rename-output: modify output filena
From: |
Tim Ruehsen |
Subject: |
Re: [Bug-wget] [PATCH] New option: --rename-output: modify output filename with perl |
Date: |
Thu, 01 Aug 2013 09:35:02 +0200 |
User-agent: |
KMail/4.10.5 (Linux/3.10-1-amd64; KDE/4.10.5; x86_64; ; ) |
On Wednesday 31 July 2013 13:45:23 Giuseppe Scrivano wrote:
> Tim Ruehsen <address@hidden> writes:
> >> Niwt apparently uses "an HTTP-based protocol" to communicate between
> >> plugins.
> >
> > Any protocol has it's pros and cons. So why not doing it the same/similar
> > way as Micah does ? That seems to be intuitive - dumping the original
> > HTTP headers and add your extension (e.g. 'X-Wget-Filename:
> > directory/filename').
> >
> > An additional Version: header as the first line to interpret makes even a
> > radical protocol change possible (instead the program could be called with
> > a --protocol-version command-line param).
>
> what do you think about passing this information trough environment
> variables? For example, "Server: foo\r\n" will be turned into
> setenv ("HTTP_SERVER", "foo") by wget before exec the external program.
>
> It will work as CGI, the main advantage is that the filter program will
> not have to parse the file.
That is basically a good idea.
Do you have in mind to keep as close to the standard CGI environment variables
as possible ? Or do you think of the CGI environment principle ?
If the latter, we should use an own namespace and let environment variables
start with WGET_.
Regards, Tim
- Re: [Bug-wget] [PATCH] New option: --rename-output: modify output filename with perl,
Tim Ruehsen <=