https://docs.python.org/3/library/fileinput.html
Dan, Yes, fileinput sounds like what I described and more. It does indeed seem to emulate the interface in programs like AWK including using "-" as a placeholder for standard input. Now all you need is to have it also do the split! ∀vi ∃. Grθß -----Original Message----- From: Python-list <[email protected]> On Behalf Of [email protected] Sent: Friday, March 26, 2021 9:43 PM To: [email protected] Subject: Re: convert script awk in python On 2021-03-26 at 21:06:19 -0400, Avi Gross via Python-list <[email protected]> wrote: > A generator that opens one file at a time (or STDIN) in a consistent > manner, would be a reasonable thing to have as part of emulating AWK. https://docs.python.org/3/library/fileinput.html -- https://mail.python.org/mailman/listinfo/python-list -- https://mail.python.org/mailman/listinfo/python-list
