on 12/30/99 9:55 PM, Makofske, David (by way of Vicki Brown) at dmakofsk@akamai.com wrote: > I have a quick question regarding passing arguments to a perl script in > MacPerl. I saw in a primer how to save a perl script as a "droplet" which > allows you to drag and drop files to be processed onto the script. What I > want to do is simply run a perl script with several text arguments. Can > somebody please point me to some documentation, tutorial or primer on what > is required to do this on a Mac? > Thanks, > David The perlport man page contains a brief bit about this. (The full title of the man page is "Writing Portable Perl.") You can find the full page at the following URL: http://www.perl.com/pub/doc/manual/html/pod/perlport.html#S_Mac_OS_ The appropriate section is this: "In the MacPerl application, you can't run a program from the command line; programs that expect @ARGV to be populated can be edited with something like the following, which brings up a dialog box asking for the command line arguments. if (!@ARGV) { @ARGV = split /\s+/, MacPerl::Ask('Arguments?'); } A MacPerl script saved as a droplet will populate @ARGV with the full pathnames of the files dropped onto the script. Mac users can use programs on a kind of command line under MPW (Macintosh Programmer's Workshop, a free development environment from Apple). MacPerl was first introduced as an MPW tool, and MPW can be used like a shell: perl myscript.plx some arguments ToolServer is another app from Apple that provides access to MPW tools from MPW and the MacPerl app, which allows MacPerl programs to use system, backticks, and piped open." HTH, JFK ==== Want to unsubscribe from this list? ==== Send mail with body "unsubscribe" to macperl-forum-request@macperl.org