Re: combining the path and fileinput modules SOLVED

2006-11-27 Thread Gabriel Genellina
At Sunday 26/11/2006 01:29, wo_shi_big_stomach wrote: for line in fileinput.input(g, inplace=1, backup='.bak'): # just print 2nd and subsequent lines if not fileinput.isfirstline(): print line.rstrip('\n') # check first line only elif fileinput.isfirstline

Re: combining the path and fileinput modules SOLVED

2006-11-25 Thread wo_shi_big_stomach
Dennis Lee Bieber wrote: > On Sat, 25 Nov 2006 07:58:26 -0800, wo_shi_big_stomach > <[EMAIL PROTECTED]> declaimed the following in > comp.lang.python: > >> File "p2.py", line 23, in ? >> for line in fileinput.input(f,): >> File >> "/System/Library/Frameworks/Python.framework/Versions/2.3/l