Skip to content

Commit

Permalink
udate
Browse files Browse the repository at this point in the history
  • Loading branch information
samholt committed Apr 16, 2024
1 parent 52f7bf2 commit 6b8ddb3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions l2mac/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from l2mac.main import generate_book, generate_codebase
12 changes: 9 additions & 3 deletions l2mac/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from typing_extensions import Annotated
import typer
from enum import Enum
from config_loader import copy_config_to_home, load_config
from l2mac.config_loader import copy_config_to_home, load_config

class Domain(str, Enum):
codebase = "codebase"
Expand Down Expand Up @@ -36,9 +36,15 @@ def run_l2mac(prompt_task: Annotated[str, typer.Argument(help="Your input prompt
return None
config = load_config()





def generate_codebase(*args, **kwargs):
kwargs['domain'] = Domain.codebase
return run_l2mac(*args, **kwargs)

def generate_book(*args, **kwargs):
kwargs['domain'] = Domain.book
return run_l2mac(*args, **kwargs)

if __name__ == '__main__':
app()

0 comments on commit 6b8ddb3

Please sign in to comment.