Update Stats #280
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
name: Update Stats | |
on: | |
schedule: | |
- cron: '30 9 * * *' # Runs at 9:30 AM UTC (3 PM IST) | |
workflow_dispatch: | |
jobs: | |
update: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Use Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- name: Install dependencies | |
run: npm ci | |
- name: Compile TypeScript | |
run: npx tsc | |
- name: Run Twitter Followers Script | |
env: | |
TWITTER_BEARER_TOKEN: ${{ secrets.TWITTER_BEARER_TOKEN }} | |
AIRTABLE_API_KEY: ${{ secrets.AIRTABLE_API_KEY }} | |
run: node twitterFollowers.js | |
- name: Run YouTube Subscribers Script | |
env: | |
YT_API_KEY: ${{ secrets.YT_API_KEY }} | |
AIRTABLE_API_KEY: ${{ secrets.AIRTABLE_API_KEY }} | |
run: node ytSubs.js | |
- name: Run Discord Members Script | |
env: | |
DISCORD_BOT_TOKEN: ${{ secrets.DISCORD_BOT_TOKEN }} | |
AIRTABLE_API_KEY: ${{ secrets.AIRTABLE_API_KEY }} | |
run: node discordMembers.js |