The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Problem In Shell Script satyakide Shell Programming and Scripting 11 09-24-2007 07:00 AM
Help! Problem with Shell Script. pektl Shell Programming and Scripting 7 05-29-2006 02:08 AM
Problem with SU or SSH in shell script sravanp UNIX for Dummies Questions & Answers 2 01-24-2006 09:00 AM
Shell Script problem bnohifi Shell Programming and Scripting 1 07-06-2005 11:02 PM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 06-29-2005
zylwyz's Avatar
Registered User
 

Join Date: Jun 2005
Location: I'm living in Unix :)
Posts: 53
Unhappy SIGINT usage in shell scripts

How can I use SIGINT in my shell scripts?

Last edited by zylwyz; 06-29-2005 at 09:38 AM.
Reply With Quote
Forum Sponsor
  #2  
Old 06-29-2005
Registered User
 

Join Date: Feb 2005
Location: Columbus OH
Posts: 133
you should use "trap" command.

I am not sure of the syntax. However I have used it as follows in the beginning of the script to capture the Ctrl-C (Interrupt)

trap " " 2

When this is used all of the Interrrupt signals to the execution of the shell script are ignored.

Jerardfjay
Reply With Quote
  #3  
Old 06-29-2005
zylwyz's Avatar
Registered User
 

Join Date: Jun 2005
Location: I'm living in Unix :)
Posts: 53
Talking

Thanks, jerardfjay!
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 04:51 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0