forked from cmu-db/dbgym
-
Notifications
You must be signed in to change notification settings - Fork 0
/
task.py
25 lines (19 loc) · 784 Bytes
/
task.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import click
from gymlib.workspace import make_standard_dbgym_workspace
from benchmark.cli import benchmark_group
from dbms.cli import dbms_group
from orchestrate.cli import manage_group
# TODO(phw2): Save commit, git diff, and run command.
# TODO(phw2): Remove write permissions on old run_*/ dirs to enforce that they are immutable.
# TODO(phw2): Rename run_*/ to the command used (e.g. tune_protox_*/).
@click.group()
@click.pass_context
def task(ctx: click.Context) -> None:
"""🛢️ CMU-DB Database Gym: github.com/cmu-db/dbgym 🏋️"""
dbgym_workspace = make_standard_dbgym_workspace()
ctx.obj = dbgym_workspace
if __name__ == "__main__":
task.add_command(benchmark_group)
task.add_command(manage_group)
task.add_command(dbms_group)
task()