Path: news.daimi.aau.dk!news-feed.inet.tele.dk!bofh.vszbr.cz!news.maxwell.syr.edu!newsfeed.internetmci.com!204.71.1.51!spamkiller.internetmci.com!pull-feed.internetmci.com!not-for-mail From: mimichae@westmont.edu (Michael Michaels) Newsgroups: comp.lang.beta Subject: Running a system shell command in BETA Message-ID: X-Newsreader: slrn (0.9.4.3 UNIX) Lines: 17 Date: Tue, 24 Feb 1998 17:22:12 GMT NNTP-Posting-Host: pulsar.westmont.edu NNTP-Posting-Date: Tue, 24 Feb 1998 12:22:12 EST Xref: news.daimi.aau.dk comp.lang.beta:11419 I recently downloaded the free Personal Edition of the Mjolner BETA system from: I have been very impressed by it and by the BETA language that it supports. Programming in BETA is a true pleasure. I do have one question, however, which came up while I was translating a script written in Python. The script reformats the output from the 'du' command (I'm using Linux). How do you run a system shell command and capture the output in BETA? I took a look at the 'startUnixProcess' pattern in the 'unixinterface' library, but have yet to understand how to use it. Am I on the right track? In Python, this is done using the following imperative: result = os.popen("du", "r").read() #capture du's output into 'result' Does anyone know how this would be done in BETA? Sincerely, Michael S. Michaels