https://github.com/motdotla/retromail
Email as real mail delivered to your doorstep.
https://github.com/motdotla/retromail
Last synced: 6 months ago
JSON representation
Email as real mail delivered to your doorstep.
- Host: GitHub
- URL: https://github.com/motdotla/retromail
- Owner: motdotla
- Created: 2013-12-08T21:56:19.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2015-09-30T02:34:31.000Z (about 10 years ago)
- Last Synced: 2025-04-11T03:13:07.933Z (6 months ago)
- Language: JavaScript
- Size: 10.3 MB
- Stars: 9
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# retromail
Email as real mail delivered to your doorstep.
## Setup
First, [Create a free account at Context.io](http://context.io) and connect your gmail account to context.io through context.io's interface.
Second, [Create a free account at Lob.com](http://lob.com).
### Production
If running on [Heroku](http://heroku.com), do the following.
```bash
git clone https://github.com/scottmotte/retromail.git
cd retromail
heroku create
heroku addons:add scheduler
heroku addons:add sendgrid
heroku config:set CONTEXTIO_KEY=value
heroku config:set CONTEXTIO_SECRET=value
heroku config:set CONTEXTIO_ACCOUNT_ID=value
heroku config:set LOB_KEY=value
heroku config:set NAME=yourname
heroku config:set EMAIL=youremail
heroku config:set ADDRESS_LINE1="Your address"
heroku config:set ADDRESS_LINE2=value
heroku config:set ADDRESS_CITY="Your City"
heroku config:set ADDRESS_STATE=value
heroku config:set ADDRESS_ZIP=value
heroku config:set ADDRESS_COUNTRY=value
git push heroku master
```Then setup, heroku to run the task.js once daily. It will look something like this.

### Development
If running locally, do the following.
Install wkhtmltopdf.
```bash
brew install wkhtmltopdf
``````bash
cp .env.example .env
```Inside that file set your `CONTEXTIO_KEY`, `CONTEXTIO_SECRET`, and `CONTEXTIO_ACCOUNT_ID`. The account id is the id of the gmail account you previously added.
Also, set the values for your name and address. `COUNTRY` must be a 2 letter country short-name code (ISO 3316)
Lastly, run it.
```bash
node task.js
```## TODO
* Support printing of photo attachments
* Support printing of pdf attachments
* Support printing of other types of attachmentsrawr.