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
help me in sending parameters from sqlplus script to unix shell script Hara Shell Programming and Scripting 2 01-29-2008 11:31 AM
Shell Script: want to insert values in database when update script runs ring Shell Programming and Scripting 1 10-25-2007 12:06 AM
here document to automate perl script that call script hogger84 Shell Programming and Scripting 3 10-22-2007 07:15 AM
returning to the parent shell after invoking a script within a script gurukottur Shell Programming and Scripting 5 09-26-2006 04:05 AM
return valuse from child script to parent script borncrazy Shell Programming and Scripting 1 08-20-2004 12:39 PM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-02-2004
Registered User
 

Join Date: Apr 2004
Location: beijing
Posts: 15
Stumble this Post!
my script :)

Code:
#!/bin/ksh
#scriptname:locktty
#writed by :javalee
#email:javalee@tom.com
#homepage:www.linuxsir.org
#script start...
reset;clear    
info="System will be locked!!! Press Waitting....."
print "\n\n\n\n\n\n\n"
for i in 9 8 7 6 5 4 3 2 1 0;do
	print -n "                \a$info$i\r"
	sleep 1
done
clear
trapper () {     
trap ' ' 2 3 20  
}
while :  ;do
	trapper  
	print "\n\n\n\n\n\n\n\n\t\t\tPlease enter unlock code:"
	stty -echo      
	read input
	case $input in
		123)	print "\t\t     Hello $USER,Today is $(date +%T)\n"
		stty echo       
		break ;;         
		*)
		clear
		continue ;;     
	esac
done
#script over
__________________
my Homepage:
http://www.linuxsir.org
Reply With Quote
Google The UNIX and Linux Forums
Forum Sponsor
Reply

Thread Tools
Display Modes




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


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

Content Relevant URLs by vBSEO 3.2.0