0.0
No commit activity in last 3 years
No release in over 3 years
A fast and lightweight mailer for ruby that uses libmimetic for generating mails
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

>= 0
 Project Readme

Pony Express

A fast and lightweight ruby mailer based on http://github.com/benprew/pony. For a more historical perspective read Pony Express.

Installation

  sudo apt-get install libmimetic-dev
  sudo apt-get install libpcre3-dev
  sudo gem install pony-express

Dependencies

  • Ruby >= 1.9.1
  • rubygems >= 1.3.5
  • ruby development libraries (debian: ruby1.9.1-dev)
  • mimetic >= 0.9.6 development libraries (debian: libmimetic-dev)
  • pcre3 development libraries (debian: libpcre3-dev)

Usage

  require "pony-express"
  mail = PonyExpress::Mail.new to: "burns@plant.local", from: "homer@home.local", via: "sendmail"
  mail.add cc: "smithers@plant.local", bcc: "carl@plant.local", replyto: "homer+work@home.local"
  mail.add subject: "Hello Mr.Burns", text: "Can I have more donuts ?", html: "<strong>More Dooooonuuuuts!</strong>"
  mail.add attachments: [ "/home/homer/donuts.png" ], headers: [{name: "X-FooBar", value: "test"}]
  mail.dispatch

Don't want to create new mail objects ? Just pass in all options to PonyExpress.mail

  PonyExpress.mail to: "burns@plant.local", from: "homer@home.local", ...

Testing

  require "pony-express"
  require "pony-express/test"
  mail = PonyExpress::Mail.new to: "burns@plant.local", from: "homer@home.local", via: "sendmail"
  mail.add subject: "Hello Mr.Burns", text: "Can I have more donuts ?"
  mail.dispatch
  assert_equal 1, PonyExpress::Test.mailbox.length

License

GPLv3