postmark plugin

fastlane Plugin Badge

Getting Started

This project is a fastlane plugin. To get started with fastlane-plugin-postmark, add it to your project by running:

fastlane add_plugin postmark

About

Fastlane plugin to send emails via Postmark.

This plugin can be very handy to notify a group of people about a new app release.

Example

notification_message_body = [
    "App v#{versionOfApp}, build: #{buildVersion} ready for download.",
    "\n",
    "What has changed in this latest release?",
    changelog
].join("\n") + "\n"

postmark(
    api_key: "server-token", # Or, set `POSTMARK_API_KEY` environment variable 
    from: "First Last <[email protected]>", # Or, set `POSTMARK_FROM_EMAIL_ADDRESS` environment variable 
    to: "[email protected], [email protected]", # comma separated list of people to send to. Or, set `POSTMARK_TO_EMAIL_ADDRESS` environment variable 
    subject: "App v#{versionOfApp} ready for download", # Or, set `POSTMARK_EMAIL_SUBJECT` environment variable 
    message_text: notification_message_body, # text only email body. If you want to use HTML instead, leave this blank. 
    message_html: "<h1>...</h1>", # HTML email body. If you want to use text instead, leave this blank. 
)

Note: It is recommended to not store the API key in the Fastfile.

Development

bundle install 

To run both the tests, and code style validation, run

bundle exec rake

To automatically fix many of the styling issues, use

bundle exec rubocop -a

You can test out the plugin using the instructions in the example Fastfile. Check out ./fastlane/Fastfile.

Issues and Feedback

For any other issues and feedback about this plugin, please submit it to this repository.

Troubleshooting

If you have trouble using plugins, check out the Plugins Troubleshooting guide.

Using fastlane Plugins

For more information about how the fastlane plugin system works, check out the Plugins documentation.

About fastlane

fastlane is the easiest way to automate beta deployments and releases for your iOS and Android apps. To learn more, check out fastlane.tools.