Skip to content

Commit

Permalink
add mastodon token
Browse files Browse the repository at this point in the history
  • Loading branch information
John Ottenlips authored and John Ottenlips committed Sep 17, 2023
1 parent ae571c8 commit e24bc30
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/wodaboard.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VB_SUB_ID: ${{ secrets.VB_SUB_ID }}
VB_SUB_KEY: ${{ secrets.VB_SUB_KEY }}
VB_SUB_SECRET: ${{ secrets.VB_SUB_SECRET }}
VB_SUB_SECRET: ${{ secrets.VB_SUB_SECRET }}
MASTODON_ACCESS_TOKEN: ${{ secrets.MASTODON_ACCESS_TOKEN }}
5 changes: 3 additions & 2 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,10 @@ type IDays =
const main = async () => {
const day = new Date().getDay();
const dayName = days[day];
const intensity = day % 3 === 0 ? "hard" : day % 2 === 0 ? "medium" : "easy";
const intensity = day % 1 === 0 ? "hard" : day % 2 === 0 ? "medium" : "easy";
const exercises = randomFourExercises(intensity);
const color = day % 3 === 0 ? "{63}" : day % 2 === 0 ? "{65}" : "{66}";
const color =
intensity === "hard" ? "{63}" : intensity === "medium" ? "{65}" : "{66}";
const text = `${color}Happy ${dayName}!${color}\nToday's WOD is:\n${exercises}`;
console.log(text);
await sendMessage(text);
Expand Down

0 comments on commit e24bc30

Please sign in to comment.