benlk / looming_midterms

A Twitter cronjob bot to count down to the midterm elections
https://twitter.com/looming_midterm
Creative Commons Attribution Share Alike 4.0 International
0 stars 0 forks source link

Script to tweet certain things on certain days #1

Open benlk opened 7 years ago

benlk commented 7 years ago

This would be a separate script, added to the main cron job script but with a 10s delay so it runs after the main tweet of day.

Stretch goal is to get the tweet ID from the countdown script and have it be the reply-to of this tweet.

Credit to @thebestsophist

benlk commented 7 years ago

Doing an array isn't particularly friendly to contributors; what would be neat is a CSV that gets parsed, and the CSV itself is pulled from a Google Sheet that accepts submissions. Periodically dump the Sheet into the CSV, then use something to parse the CSV to get date, text, link.

Parts:

Parsing tweets-for-dates spreadsheet sounds like https://copytext.readthedocs.io/en/stable/

Fetching the spreadsheet is gonna be more complex; might just be a manual task to run for the first few weeks.

benlk commented 6 years ago

Alternate plan: parse Tyler Fisher's fork of https://github.com/democrats/election-calendar/tree/master/2018 using jupyter/pandas a la firstpythonnotebook.org to get the things I need, and then paste that CSV into a Google Sheet so it can be group-edited. Download spreadsheet as csv, parse tweets-for-dates, | xargs t