tweet #386
This file contains hidden or 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: tweet | |
| on: | |
| push: | |
| branches: ['test'] # push to this branch to test toots | |
| schedule: | |
| - cron: '41 15 * * *' # trigger at 3:41 pm UTC (8:41 AM PST) | |
| jobs: | |
| tweet: | |
| runs-on: ubuntu-latest | |
| env: | |
| RTOOT_DEFAULT_TOKEN: ${{ secrets.RTOOT_DEFAULT_TOKEN}} | |
| TWITTER_CONSUMER_API_KEY: ${{ secrets.TWITTER_CONSUMER_API_KEY }} | |
| TWITTER_CONSUMER_API_SECRET: ${{ secrets.TWITTER_CONSUMER_API_SECRET }} | |
| TWITTER_ACCESS_TOKEN: ${{ secrets.TWITTER_ACCESS_TOKEN }} | |
| TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }} | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@v4 | |
| - name: Setup R | |
| uses: r-lib/actions/setup-r@v2 | |
| - name: Install system dependencies | |
| run: sudo apt-get install libudunits2-dev libcurl4-openssl-dev libgdal-dev | |
| - name: Install R Dependencies | |
| uses: r-lib/actions/setup-renv@v2 | |
| - name: Create message and tweet toot | |
| run: Rscript tweet_toot.R |