Getting Started
Introduction
Perl IDEs
History
Advice
Tools
Mini-Tutorial
Tutorial
Code Snippets

Resources
Top Sites
More Tutorials
Books
Magazines
Articles
NewsLetters
Mailing Lists
NewsGroups
Forums
User Groups
Talk Shows
Blogs
Clothing

GBIC >> Perl >> Information Center Tutorials >> System Calls

Perl Information Center Tutorials - System Calls
These tutorials were written to help you get a quick, but thorough, understanding of Perl - the scope of the language as well as it's specific capabilities.

Beginners Built-In Functions     Advanced CGI Applications

System Calls

    • Timers
     sleep, wait
    • Process Calls    
     exec, system

System Calls Functions Reference
Here's a quick reference of the available system call functions, in alphabetical order.

Unless otherwise noted, these functions operate on $_ by default.

  • exec - executes a system command and never returns
        exec PROGRAM list
    
        exec "notepad";     # opens Notepad. Perl script ends.
        
  • sleep - stops script execution for specified seconds
        sleep EXPR
     
        sleep 5;            # pauses for 5 seconds
        
  • system - executes a system command and returns after the called command completes
        system PROGRAM LIST 
    
        system 'notepad'    # opens Notepad, waits for it to complete
        
  • wait - waits for a child process to terminate
        wait
        

If you have any suggestions or corrections, please let me know.