Doug Potter wrote:
> for i in routers:
> os.system('/bin/touch' %s) % i
>
> of course this dosn't work.
>
> Is there a simple way to get this done?
Yep, someone already answered that you can create the file in write mode
and then close it, but I wanted to add a little more in why your
sol
Doug Potter wrote:
> Hi,
>
> I at trying to create a bunch of text files in a single directory on a
> Linux system,
> something like this.
>
> import os
>
> routers = ['adnc-6321', 'adnp-2341', 'adnw-2632']
>
> for i in routers:
> os.system('/bin/touch' %s) % i
>
> of course this dosn't w
Doug Potter wrote:
> Hi,
>
> I at trying to create a bunch of text files in a single directory on a
> Linux system,
> something like this.
>
> import os
>
> routers = ['adnc-6321', 'adnp-2341', 'adnw-2632']
>
> for i in routers:
> os.system('/bin/touch' %s) % i
I think you're close, just