LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 06-10-2007, 03:11 PM   #1
Intimidator
Member
 
Registered: Mar 2005
Distribution: FC4
Posts: 83

Rep: Reputation: 15
Procmail filtering


how do i execute a script(test.py) on every new mail using .procmailrc?
the following code isn't working..
Code:
:0
| cat&>$HOME/temp_mail && \
python $HOME/test.py
In the above example i am writing the new mail to temp_mail and executing the script which takes temp_mail as argument..This isn't working..how can i fix this?

Last edited by Intimidator; 06-10-2007 at 03:42 PM.
 
Old 06-10-2007, 04:55 PM   #2
alunduil
Member
 
Registered: Feb 2005
Location: San Antonio, TX
Distribution: Gentoo
Posts: 684

Rep: Reputation: 62
If you want the script ran on _every_ new message just place it in your ~/.forward, and use procmail elsewhere.

Code:
echo "|<path to script>" >> ~/.forward
Regards,

Alunduil
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
procmail filtering for nonexistant user juu801 Linux - Software 4 10-06-2006 07:33 PM
Filtering outgoing mail through Procmail SlackDaemon Linux - Newbie 2 06-22-2006 07:05 AM
Procmail Filtering Using a Full Subject Line lmcilwain Linux - Software 3 02-08-2006 01:07 PM
Procmail not filtering WiWa Linux - Networking 0 07-06-2004 02:22 PM
Procmail not filtering tomac Linux - General 0 05-26-2004 03:15 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 02:11 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