A CLI script for processing CSV data and sending emails using:
- Cobra: to create CLI application
- Task: for task runner
- golangci-lint: for linting and formatting
- pgx: communicating with PostgreSQL
- testify: for testing
You need to update the variables in Taskfile.yml to run for different environments and testing purpose:
vars:
ENV: dev
AWS_PROFILE: dev
TEST_EMAIL: daniel.guo@vivalabs.com.au
SENDER: no-reply@the-hub.ai
PIF_INPUT: data/pif_club_transfer.csv
DD_INPUT: data/dd_club_transfer.csv
export AWS_PROFILE=xxx
# Build and run PIF transfers
task send-email-pif
# Build and run DD transfers
task send-email-dd
# Run tests
task test
# Run tests with coverage
task test:coveragetask docker:send-email-pif
task docker:send-email-ddtask docker:test