This repository has been archived by the owner on Jan 6, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from cadusk/feature-workflow
- Loading branch information
Showing
3 changed files
with
47 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# This workflow will build a golang project | ||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go | ||
|
||
name: Send daily budget notification | ||
|
||
on: | ||
workflow_dispatch: | ||
# schedule time is UTC. 12pm UTC = 7am EST | ||
schedule: | ||
- cron: "0 12 * * *" | ||
|
||
env: | ||
SENDGRID_TOKEN: ${{ secrets.SENDGRID_TOKEN }} | ||
SENDGRID_TEMPLATE_ID: ${{ secrets.SENDGRID_TEMPLATE_ID }} | ||
SENDGRID_MAIL_FROM: ${{ secrets.SENDGRID_MAIL_FROM }} | ||
SENDGRID_MAIL_FROM_NAME: "Budget Notification Service - GitHub Action" | ||
SENDGRID_MAIL_TO: ${{ secrets.SENDGRID_MAIL_TO }} | ||
YNAB_TOKEN: ${{ secrets.YNAB_TOKEN }} | ||
YNAB_BUDGET_ID: ${{ secrets.YNAB_BUDGET_ID }} | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
with: | ||
go-version: '1.23' | ||
# it should be possible to cache dependencies... but let's make this work first. | ||
# cache-dependency-path: go.sum | ||
|
||
- name: Build | ||
run: go run ./cmd/ynot/main.go | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters