Hello everybody,
I am trying to divide a configuration file (configs) in the form of:
ServerAdmin webmas...@foo.com
ServerName www.foo.com
DocumentRoot /home/public/web/htdocs/foo.com
ScriptAlias /cgi-bin/ /home/public/web/htdocs/foo.com/cgi-bin/
[...]
ServerAdmin webmas...@bar.com
Server
-Agent: KNode/4.13.3
> Message-ID:
>
> Toni Fuente via Tutor wrote:
>
> > Hello everybody,
> >
> > I am trying to divide a configuration file (configs) in the form of:
> >
> >
> > ServerAdmin webmas...@foo.com
> > ServerName www.foo.com
Hi,
I've got this script that goes through an httpd conf file, and gets the
related bits of it for a site, and writes a new config with values that
I am interested. The problem is that it finds the first chunk and
returns it, but I need to go to the end of all chunks list, because
there are also s
* David Rock [2017-03-13 11:28:57 -0500]:
> > On Mar 13, 2017, at 10:54, Toni Fuente via Tutor wrote:
> >
> > Hi,
> >
> > I've got this script that goes through an httpd conf file, and gets the
> > related bits of it for a site, and writes a new co
* Peter Otten <__pete...@web.de> [2017-03-13 19:57:38 +0100]:
>
> Toni Fuente via Tutor wrote:
>
> > Hi,
> >
> > I've got this script that goes through an httpd conf file, and gets the
> > related bits of it for a site, and writes a new config with
>
> for item in itertools.chain.from_iterable(chunk):
>...
>
> will work, too, without the consumption of time and memory needed to build
> the list.
>
Thank you Peter, yes it works as I wanted like that.
___
Tutor maillist - Tutor@python.org
T