Skip to content

Commit

Permalink
Merge pull request #17 from rrigato/dev
Browse files Browse the repository at this point in the history
script for automating putting message board posts
  • Loading branch information
rrigato authored Feb 18, 2024
2 parents fe90443 + f244e42 commit 271fb69
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,7 @@ pip install -r requirements/requirements-dev.txt
python -m unittest
```

# application-link
[Example message board post](https://www.reddit.com/r/Toonami/comments/1ao9p0t/cyborg_009_episode_1_and_episode_2_rewatch/) created by the application

Since the human condition is such that we always prefer to watch the same tv series over again since it is good and familiar as opposed to trying something new we might not like, this application is desperately needed.
Since the human condition is such that we always prefer to watch the same tv series over again since it is good and familiar as opposed to trying something new we might not like, this application is desperately needed.
35 changes: 35 additions & 0 deletions scripts/future_message_board_post.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
first_episode="Episode 3"
first_episode_link="https://pluto.tv/en/on-demand/series/602c16c0f2c1bd001af24c31/season/1/episode/60394e6c6c2a2d001410c37b"
first_episode_title="The Assassin of Flash"
item_sort_key="cyborg009"
post_date="2024-02-17"
#for Test subreddit
# rewatch_flair_id="6b39b4a6-be2f-11e8-ac14-0e2593696d0a"
rewatch_flair_id="693636e6-ba17-11e3-a364-12313d31e5b1"
second_episode="Episode 4"
second_episode_link="https://pluto.tv/en/on-demand/series/602c16c0f2c1bd001af24c31/season/1/episode/60394e6d6c2a2d001410c3b2"
second_episode_title="At the End of the Battle"
show_title_name="Cyborg 009"
#for Test subreddit post
#subreddit_name="Test"
subreddit_name="Toonami"
table_title="Episode | Source\n-------|------\n"


# '"$<variable_name>"' enables string concatenation
aws dynamodb put-item \
--table-name rewatch_shared_table \
--item '{
"PK": {"S": "rewatch#'"$post_date"'"},
"SK": {"S": "'"$item_sort_key"'"},
"flair_id": {"S": "'"$rewatch_flair_id"'"},
"post_title": {"S": "'"$show_title_name"' '"$first_episode"' and '"$second_episode"' Rewatch"},
"post_message": {
"S": "'"$table_title"'**'"$first_episode_title"'** | ['"$first_episode"']('"$first_episode_link"')\n**'"$second_episode_title"'** | ['"$second_episode"']('"$second_episode_link"')"
},
"subreddit": {
"S": "'"$subreddit_name"'"
}
}' \
--region us-east-1

0 comments on commit 271fb69

Please sign in to comment.