Displaying 1 result from an estimated 1 matches for "assetsubmithandl".
Did you mean:
assetsubmithandler
2006 Jul 25
0
writing an email file attachment to the filesystem
I''m having some difficulty writing an email file attachment to the
filesystem.
I have the following line in my /etc/aliases
webname: "| /usr/bin/ruby /home/webname/webapp/script/runner
''AssetSubmitHandler.receive STDIN.read''"
Everything works up to this point, it picks up the email and tries to
process it.
When I go to write the file using (in my AssetSubmitHandler class):
File.open(base_dir+asset.path,File::CREAT|File::TRUNC|File::WRONLY,0666){
|f|
f.write(attachment.read)
}...