forked from CU-DBMI/template-uv-python-research-software
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcli.py.jinja
More file actions
36 lines (27 loc) · 723 Bytes
/
Copy pathcli.py.jinja
File metadata and controls
36 lines (27 loc) · 723 Bytes
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
26
27
28
29
30
31
32
33
34
35
36
"""
CLI for {{ python_package_name }}
"""
import fire
from {{ python_package_name }}.main import show_message
class {{ python_package_name }}CLI:
def show_message(
self,
message: str = "Hello, world!",
) -> str:
"""
CLI interface for show_message.
Args:
message (str):
The message to print.
Defaults to 'Hello, world!'.
Returns:
pd.DataFrame:
A DataFrame containing the message.
"""
# prints the message to screen
print(show_message(message=message))
def trigger() -> None:
"""
Trigger the CLI to run.
"""
fire.Fire({{ python_package_name }}CLI)