Jekyll email plugin. Send emails with simple command.
Add this line to your jekyll application's Gemfile:
group :jekyll_plugins do
gem 'jekyll-email', git: 'git@github.com:kisakov/jekyll-email.git'
end
And then execute:
$ bundle
Create .env file in root of your jekyll's project
MAIL_HOST=mail.example.com
MAIL_PORT=587
MAIL_DOMAIN=example.com
MAIL_USER=user@example.com
MAIL_PASSWORD=password
MAIL_FROM=from@example.com
RECIPIENTS="recipient1@gmail.com,recipient2@gmail.com"
You can read about gmail authentication there
Also exclude .env file from your git repository in .gitignore
And finaly add these to your _config.yml
domain: "http://your_domain.com"
mail_subject: "New post"
mail_intro: "Hello"
mail_read_more: "read next..."
mail_closing: "Good Bye"
$ jekyll mail # send last post
$ jekyll mail 2013-08-01-post # send post with name 2013-08-01-post
$ jekyll mail -preview # Open email for preview without sending
$ jekyll mail --recipients "recipient1@gmail.com, recipient2@gmail.com" # Send an email only to specific recipients
After checking out the repo, run bin/setup
to install dependencies. Then, run rake false
to run the tests. You can also run bin/console
for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run bundle exec rake install
. To release a new version, update the version number in version.rb
, and then run bundle exec rake release
, which will create a git tag for the version, push git commits and tags, and push the .gem
file to rubygems.org.
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/jekyll-email.