On Thu, Jan 28, 2010 at 9:44 PM, Dennis Lee Bieber <wlfr...@ix.netcom.com> wrote: > On Thu, 28 Jan 2010 11:24:28 -0800 (PST), Joan Miller > <pelok...@gmail.com> declaimed the following in > gmane.comp.python.general: > > > On 28 ene, 19:16, Josh Holland <j...@joshh.co.uk> wrote: > > > On 2010-01-28, Joan Miller <pelok...@gmail.com> wrote: > > > > > > > I've to call to many functions with the format: > > > > > > >>>> run("cmd") > > > > > > Check the docs on os.system(). > > No. I've a function that uses subprocess to run commands on the same > > shell and so substitute to bash scrips. But a script full of run > > ("shell_command --with --arguments") is too verbose. > > I shall blaspheme, and suggest that maybe the language you want to > use is REXX (ooREXX or Regina).
Sounds like the REXX designers already got the blaspheming covered when they came up with such an inelegant-sounding feature... > By default, ANY statement that can not be confused for a REXX > language statement is sent to the currently defined command handler > (Which on most OSs is equivalent to Python's os.system() call; the late > Amiga, and IBM's mainframe OS had features that support defining other > applications as command handlers). > > A common practice is to put quotes about the first word of the > command to ensure it gets treated as external command. Cheers, Chris -- http://blog.rebertia.com -- http://mail.python.org/mailman/listinfo/python-list