We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c3ad1dc commit b0e1be4Copy full SHA for b0e1be4
ygka/cli/retrieve_stdin.py
@@ -0,0 +1,7 @@
1
+import sys
2
+
3
+_stdin = None if sys.stdin.isatty() else sys.stdin.read()
4
5
6
+def retrieve_stdin():
7
+ return _stdin
ygka/cli/ygka.py
@@ -1,8 +1,10 @@
from rich import print as pprint
from .cli_app import cli_app
+from .retrieve_stdin import retrieve_stdin
@cli_app.command()
-def ygka_command():
8
- pprint('[bold]Hello World![/bold]')
+def ygka_command(query: str):
9
+ stdin = retrieve_stdin()
10
+ pprint({'stdin': stdin, 'query': query})
0 commit comments