Skip to content

Commit 8a9a325

Browse files
committed
reorganized shared components into overviews (read only) and user_flows (mutates db)
1 parent 3b98d98 commit 8a9a325

File tree

9 files changed

+12
-5
lines changed

9 files changed

+12
-5
lines changed

src/fob/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# This is the main entry point for the application.
12
import sys
23
import argparse
34
from dataclasses import dataclass

src/fob/commands/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# Each module in this 'commands' directory has an identically named function that is called by the main.py script.
12
from fob.commands.help import help
23
from fob.commands.gm import gm
34
from fob.commands.sup import sup

src/fob/commands/components/__init__.py

Lines changed: 0 additions & 2 deletions
This file was deleted.

src/fob/commands/gm.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44

55
from rich.pretty import pprint, Pretty
66
from rich import print
7-
from rich.layout import Layout, Panel
7+
from rich.layout import Layout
8+
from rich.panel import Panel
89
from rich.progress import Progress, TextColumn, BarColumn, TaskProgressColumn, ProgressColumn
910
from rich.console import Console, Group
1011
from rich.rule import Rule
@@ -13,7 +14,8 @@
1314
from tinydb import where, Query
1415

1516
from fob.db import MonthBlockData, TinyDBWrapper, checklist_complete
16-
from fob.commands.components import month_overview, display_checklist
17+
from fob.commands.overviews import month_overview
18+
from fob.commands.user_flows import display_checklist
1719

1820
class InvalidUserInput(Exception):
1921
'''
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# This 'overviews' directory contains read-only visualizations of database content
2+
from fob.commands.overviews.month_overview import *

src/fob/commands/sup.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
from argparse import Namespace
22

33
from fob.db import TinyDBWrapper
4-
from fob.commands.components import month_overview, day_checklist
4+
from fob.commands.overviews import month_overview
5+
from fob.commands.user_flows import day_checklist
56

67
def sup(args: Namespace, db: TinyDBWrapper) -> None:
78
month_overview(args, db)
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# This user_flows directory contains sequential user interactive flows that modify the database
2+
from fob.commands.user_flows.day_checklist import *

0 commit comments

Comments
 (0)