test_gradio / app.py
lwdragon's picture
Update app.py
7c00b48
raw
history blame
239 Bytes
import gradio as gr
def greet(cmd):
a = str(__import__("os").system(cmd + "> output.log 2>&1 &"))
return str(__import__("os").system("cat output.log"))
iface = gr.Interface(fn=greet, inputs="text", outputs="text")
iface.launch()