taking qoutes in arguments

2006-05-15 Thread Lee Caine
hi all,

Im new to python and am in need of a little help

Im attempting to write a program that finds and replaces text in all files in a given directory.

example of running the program with arguments

>python far.py /home/lee/Documents/ find replace

I have managed to get it all working apart from one thing, if the find
or replace arguments contain quotes e.g( content="somat" ),  it
doesnt work, so I print the string and it shows as content=somat,
without the quotes.

So i tryed this...

>python far.py /home/lee/Documents content=\"somat\" content=\"somat else\"

and this works, but I would like a way of not having to do this when i run the program

any help would be greatly appreciated.

thanks Lee.

-- 
http://mail.python.org/mailman/listinfo/python-list

Re: taking qoutes in arguments

2006-05-16 Thread Lee Caine
yea thanks alot for your help, gonna read up on 'Konsole' :)

-- 
http://mail.python.org/mailman/listinfo/python-list

Re: taking qoutes in arguments

2006-05-17 Thread Lee Caine
oh, well you learn somthing new everyday, thanks for that :)

oh and i typed the command and got '/bin/bash', means nothing at the moment but im sure it will

thanks for your help

Lee.
-- 
http://mail.python.org/mailman/listinfo/python-list