[plug] re: script file

Leon Brooks leon at brooks.smileys.net
Mon Aug 14 00:01:57 WST 2000


jlmiller at mmtnetworks.com.au wrote:
> How do I make a script file active, eg after writing the file
> I want to run it.

    chmod a+x scriptfilename

If you only want to run it once, just do...

    sh scriptfilename

...instead. If the first line says...

    #!/path/to/interpreter

...then that interpreter is used to run the script. For example, this is
a common method for making executable perl scripts:

    #!/usr/bin/perl
    perl code
    perl code
    perl code etc...

-- 
If life is merely a joke, the question remains: for whose amusement?



More information about the plug mailing list