06-27-2006
Send email to user when condition met
Hi all,
I plan to write a shell script to inform users on their task when certain condition met.
example: If a
then email user on action a
else
email user on action b.
I'm pretty new in scripting, appreciate any suggestions.
Thanks.
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
Hi
I am using mailx to send email and am wondering if there is a way I can send the email from a different user than the user logged in.
something like do-not-reply@xyz.com
Thank you. (1 Reply)
Discussion started by: rakeshou
1 Replies
2. Shell Programming and Scripting
I am having trouble figuring this code
I want to grep a text from a file and if it match certain text it break out of the loop or it should continue searching for the text
Here is what I have written but it isn't working
while true
f=`grep 'END OF STATUS REPORT' filename`
do
if ... (9 Replies)
Discussion started by: Issemael
9 Replies
3. Shell Programming and Scripting
Hello all, I created the below script....and it seemed to be working fine. My problem is i want the script to ignore rest of the things if my condition is not met but do not exit....
#!/bin/ksh
###########################
###########################
# Set name of the listener, this... (2 Replies)
Discussion started by: abdul.irfan2
2 Replies
4. UNIX for Advanced & Expert Users
All,
I wrote the following section of code (which logically in PHP would of worked):
tmpPATH=${1}
tmpTAG=${2}
if
then
while read tmpTAG tmpPATH
do
fi
echo $tmpTAG
echo $tmpPATH
if
then
done < ./config.cfg
fi (4 Replies)
Discussion started by: Cranie
4 Replies
5. UNIX for Advanced & Expert Users
only wc -l greater than 0 then send email to owner, otherwise do nothing.
ie.
result=powermt display dev=all|awk '{print $7}'|grep -i dead|wc -l
if
then
echo $result
else
:
fi
mailx -s "there is dead path (s)" "mymail@mydomain.com"
-----------
it is not working... (2 Replies)
Discussion started by: orafup
2 Replies
6. Shell Programming and Scripting
Hello everyone,
I am trying to create function or script to send email from an address book file.
Here is the file format i have,
Susan:Miller:M:123 Main Street:Philadelphia:PA:17101:666-645-6666:Susan.Miller@gmail.com:07/12/1979 Robert:Langan:S:32 North Avenue:San... (5 Replies)
Discussion started by: asistant
5 Replies
7. Shell Programming and Scripting
I created a bash script that gets a file formats it, sends an email to the user(s), however, for whatever reason, it will send an email per line with all of the lines in it, so essentially the user will get 10 duplicate emails with the same 10 results. I've modified the script to put the results of... (2 Replies)
Discussion started by: hotdang
2 Replies
8. Shell Programming and Scripting
Hi All,
Seeking for your assistance to get the records once the $2 met the condition.
Ex. file 1.txt
123455,10-Aug-2020 07:33:37 AM,2335235,1323534,12343
123232,11-Aug-2015 08:33:37 PM,4234324,1321432,34364
Output:
123455,10-Aug-2020 07:33:37 AM,2335235,1323534,12343
What i did... (5 Replies)
Discussion started by: znesotomayor
5 Replies
9. Shell Programming and Scripting
Hi All,
Seeking for your assistance on how to append the specific string when $3 condion met.
ex. file1.txt
ar0050046b16,5,888,0,0,0,0.00,0.00,0.00,0.00,25689.55
ar0050046b16,5,0,0,0,0,0.00,0.00,0.00,0.00,25689.55
ar0050046b16,5,0,0,0,0,0.00,0.00,0.00,0.00,25689.55
expected output:... (5 Replies)
Discussion started by: znesotomayor
5 Replies
10. UNIX for Beginners Questions & Answers
I have a file.txt containing the following:
Query= HWI-ST863:386:C5Y8UACXX:3:2302:16454:89688 1:N:0:ACACGAAT
Length=100
Score E
Sequences producing significant alignments: (Bits) Value
... (2 Replies)
Discussion started by: tons92
2 Replies
LEARN ABOUT DEBIAN
mojomojo::controller::user
MojoMojo::Controller::User(3pm) User Contributed Perl Documentation MojoMojo::Controller::User(3pm)
NAME
MojoMojo::Controller::User - Login/User Management Controller
DESCRIPTION
This controller performs user management: registration, login, logout, password recovery and profile editing.
ACTIONS
login (/.login)
Log in through the authentication system.
logout ( /.logout )
Log out the user.
users ( /.users )
Show a list of the active users with links to the pages they edited.
page_user
Show a user's preferences
prefs ( .prefs )
Main user preferences screen.
password ( .prefs/password )
Change password action.
template: user/password.tt
recover_pass
Email a user a new password
register ( /.register )
Show new user registration form.
template: "user/register.tt"
is_account_taken
Test to see if a login or email is already in use.
do_register ( /.register )
New user registration processing.
templates: "user/password.tt", "user/validate.tt"
validate ( /.validate )
Validation of user email. Will accept a md5_hex mailed to the user earlier. Non-validated users will only be able to log out.
reconfirm
Send the confirmation mail again to another address.
profile ( .profile )
Show user profile.
editprofile
Form to edit a person's profile
do_editprofile
Apply the edits to a person's profile
AUTHOR
David Naughton <naughton@cpan.org>, Marcus Ramberg <mramberg@cpan.org>
LICENSE
This library is free software. You can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2011-09-02 MojoMojo::Controller::User(3pm)