Clojure-powered automated email sender for birthdays and anniversaries.
Works with Gmail or Zoho, currently.
On GitHub, a fork of a public repository must also be public:
A fork is a new repository that shares code and visibility settings with the original “upstream” repository.
(One nice thing about a GitHub fork is that syncing with the original project can be done easily on the GitHub UI.)
However, it's probably not a good idea to expose your friends' personal details, so one fairly simple way of making use of this project in a private repo (while maintaining the ability to periodically integrate upstream changes) is to create a private fork—see this Stack Overflow answer for a step-by-step guide (unfortunately, this means that syncing your repo with upstream changes via GitHub's UI isn't possible).
git clone --bare https://github.com/blairnangle/birthdays.git
cd birthdays.git
git push --mirror https://github.com/yourname/birthdays-private.git
cd ..
rm -rf birthdays.git
git clone https://github.com/yourname/birthdays-private.git
cd birthdays-private
[make some changes]
git commit
git push origin main
git remote add public https://github.com/blairnangle/birthdays.git
git pull public main
git push origin main
This project uses Omniconf to get application-level preferences and secrets
into code. See src/birthdays/config.clj
for a list of config options. Less obvious values are explicitly mentioned
below.
Secret values should find there way into the code as GitHub Actions secrets -> environment variables -> read into config by Omniconf.
If you use Gmail, this value should be gmail
. If you use Zoho Mail, this value should be zoho
.
Save this as a GitHub Actions secret named EMAIL_PROVIDER
.
Save this as a GitHub Actions secret named SENDER_EMAIL
.
Save this as a GitHub Actions secret named PASSWORD
.
You need a Google App Password to send emails on behalf of your Gmail account. This can be done here.
If you have multifactor authentication (MFA) enabled for your Zoho Mail account, you will need to create an Application-Specific Password - see their docs. Even if you don't have MFA enabled, it is still a good idea to create one of these. Otherwise, a bad actor that gets their hands on your password will have access to everything in your account.
Emails to cc (can be omitted entirely). Save this as a GitHub Actions secret named CC
.
For one cc recipient, e.g.:
export [email protected]
For multiple cc recipients, e.g.:
Goes at the bottom of every email. Configure in the config
namespace.
Path to file holding birthdays and anniversaries data. Configure in the config
namespace.
clojure -M -m birthdays.birthdays
This program runs at 07:00 UTC daily in a GitHub Actions workflow from the commandline, scheduled by cron.
Distributed under an MIT License.