Spaces:
Running
Running
Bachstelze commited on
Commit ·
d387557
1
Parent(s): 67d0d5f
set up GitHub Actions and add a simple gradio app
Browse files- .github/workflows/push_to_hf_space.yml +19 -0
- app.py +7 -0
.github/workflows/push_to_hf_space.yml
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
name: Sync with Hugging Face Hub
|
| 2 |
+
|
| 3 |
+
on:
|
| 4 |
+
push:
|
| 5 |
+
branches:
|
| 6 |
+
- main
|
| 7 |
+
|
| 8 |
+
jobs:
|
| 9 |
+
build:
|
| 10 |
+
runs-on: ubuntu-latest
|
| 11 |
+
steps:
|
| 12 |
+
- name: Sync with Hugging Face
|
| 13 |
+
uses: nateraw/huggingface-sync-action@v0.0.4
|
| 14 |
+
with:
|
| 15 |
+
github_repo_id: othmanreem/Data-intensive-systems
|
| 16 |
+
huggingface_repo_id: lnuDataProject/A1
|
| 17 |
+
repo_type: space
|
| 18 |
+
space_sdk: gradio
|
| 19 |
+
hf_token: ${{ secrets.HF_TOKEN }}
|
app.py
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import gradio as gr
|
| 2 |
+
|
| 3 |
+
def greet(name):
|
| 4 |
+
return "Hello " + name + "!!"
|
| 5 |
+
|
| 6 |
+
iface = gr.Interface(fn=greet, inputs="text", outputs="text")
|
| 7 |
+
iface.launch()
|