Archive Discover Weekly Playlist #32
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: Archive Discover Weekly Playlist | |
on: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
schedule: | |
# Run Mondays at 7:57 | |
- cron: "57 7 * * 1" | |
jobs: | |
archive_discover_weekly: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout main | |
uses: actions/checkout@v4 | |
- name: Setup Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.12' | |
cache: 'pip' | |
- name: Install Python deps | |
run: pip install -r requirements.txt | |
- name: Run playlist archiver script | |
shell: bash | |
env: | |
SPOTIFY_CLIENT_ID: ${{ secrets.SPOTIFY_CLIENT_ID }} | |
SPOTIFY_CLIENT_SECRET: ${{ secrets.SPOTIFY_CLIENT_SECRET }} | |
SPOTIFY_ACCESS_TOKEN: ${{ secrets.SPOTIFY_ACCESS_TOKEN }} | |
SPOTIFY_REFRESH_TOKEN: ${{ secrets.SPOTIFY_REFRESH_TOKEN }} | |
run: > | |
python playlist-archiver-for-spotify.py | |
"$SPOTIFY_CLIENT_ID" "$SPOTIFY_CLIENT_SECRET" | |
"$SPOTIFY_ACCESS_TOKEN" "$SPOTIFY_REFRESH_TOKEN" | |
"Discover Weekly" "DW - %b %e" |