Logo 
Search:

Unix / Linux / Ubuntu Articles

Submit Article
Home » Articles » Unix / Linux / Ubuntu » Homework HelpRSS Feeds

Write a Script to Broadcast a message to a specified user when the user loged on any terminal

Posted By: Hannah Campbell     Category: Unix / Linux / Ubuntu     Views: 5467

Write a Script to Broadcast a message to a specified user when the user loged on any terminal

Code for Write a Script to Broadcast a message to a specified user when the user loged on any terminal in Unix / Linux / Ubuntu


echo "Enter User Name :- \c"
read user
who -a > who -file
check-user = 'grep -c $user who -file'if [$checkuser = 0];then
write $user "welcome to new world"
  
Share: 



Hannah Campbell
Hannah Campbell author of Write a Script to Broadcast a message to a specified user when the user loged on any terminal is from Toronto, Canada.
 
View All Articles

Related Articles and Code:


 

Other Interesting Articles in Unix / Linux / Ubuntu:


 
Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

 
No Comment Found, Be the First to post comment!