aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/oguri/cli.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/oguri/cli.py b/src/oguri/cli.py
index 96a5f5f..3410610 100644
--- a/src/oguri/cli.py
+++ b/src/oguri/cli.py
@@ -18,18 +18,22 @@ def schedule(day, reverse):
"""
Shows the airing schedule for a given day.
- DAY can be 'today', 'tomorrow', or an integer representing the number of days from now.
+ DAY can be "today", "tomorrow", "yesterday", or an integer representing the number of days from now.
"""
days_offset = 0
if day == "tomorrow":
days_offset = 1
+ elif day == "yesterday":
+ days_offset = -1
elif day != "today":
try:
days_offset = int(day)
except ValueError:
- raise click.BadParameter('DAY must be "today", "tomorrow", or an integer.')
+ raise click.BadParameter(
+ 'DAY must be "today", "tomorrow", "yesterday", or an integer.'
+ )
asyncio.run(schedule_logic.show_schedule(days_offset, reverse))