Skip to content

Subscribe magazines published on Github and send it to my Kindle

Notifications You must be signed in to change notification settings

xieyuschen/sub-magazines

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sub-Magazines

Sub-magazines subscribes to the magazine repo and sends newly added epub format files to my Kindle by email. It checks the latest commit on the master branch daily with the help of scheduled github action. Currently, it supports hardcoded destination only.

Configuration Scheme

The Github action relies on configurations in environment variables.

  • SMTP_CONFIG:
    The format of SMTP_CONFIG is JSON. It could be set up directly on github page. If you want to set up it by shell, please squash multiple lines to one line and add \ before ".

    {
      "name": "name",
      "email": "email@demo.com",
      "password": "password",
      "host": "localhost",
      "destination": "destination"
    }
  • TOKEN_GITHUB: String format.

Local Debug

Exporting the environment variables like this:

export SMTP_CONFIG="{\"name\":\"xieyuschen\",\"email\":\"example@gmail.com\",\"password\":\"your-password\",\"host\":\"smtp.gmail.com\",\"destination\":\"destination@kindle.cn\"}"
export TOKEN_GITHUB=github_blablabla