Download app.py from elbhorgo/test: direct link, hf CLI and curl.
- Browser
- Download file 399 Bytes
-
https://huggingface.co/spaces/elbhorgo/test/resolve/main/app.py
- Command line
-
hf download hf://spaces/elbhorgo/test/app.py
-
curl -L -o app.py https://huggingface.co/spaces/elbhorgo/test/resolve/main/app.py
399 Bytes
| import gradio as gr | |
| import os | |
| read_key = os.getenv("HF_TOKEN") | |
| usr=os.getenv("usr") | |
| passwrd=os.getenv("password") | |
| def auth_user(username,password): | |
| if username==usr and password==passwrd: | |
| return True | |
| else: | |
| return False | |
| with gr.Blocks() as app: | |
| gr.Textbox("my text") | |
| #inc = gr.load("elbhorgo/marketing",hf_token=read_key, src="spaces") | |
| app.launch(auth = auth_user) | |