LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-23-2004, 12:45 PM   #1
rohan208
Member
 
Registered: May 2004
Posts: 75

Rep: Reputation: 15
acpi and bash script!


Hey I have enables acpi on my RH9. So I want my computer to do a "shutdown -h now" when both the "reset and power" butten are pressed at the same time. Any Idea how to write bash script that does that?
Right nwo I can run any script I want when i press the power button. I can add the script to /etc/acip/events/power.conf to make it execute when the pwer button or the reset is pressed.

Or I'd like to be able to shutdown my system if the power button is pressed three times in 5 seconds. Is that possible?

Rohan
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
bash script azx Linux - Newbie 6 08-18-2005 10:36 AM
ACPI on BASH? Cornholio Linux - Laptop and Netbook 5 03-30-2005 11:20 AM
send automatic input to a script called by another script in bash programming jorgecab Programming 2 04-01-2004 12:20 AM
bash script - incrementing a filename in a script tslinux Programming 10 08-05-2003 11:58 PM
bash script prob: how can i tell the script that a 'dd' has finished? Frustin Linux - General 2 04-02-2003 05:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration