Spaces:
Running
Running
Merge pull request #51 from borisdayma/fix-action
Browse files- .github/workflows/main.yml +18 -13
.github/workflows/main.yml
CHANGED
@@ -1,19 +1,24 @@
|
|
1 |
-
|
2 |
|
3 |
-
name: max-file-size
|
4 |
-
|
5 |
-
uses: ActionsDesk/lfs-warning
|
6 |
-
|
7 |
-
with:
|
8 |
-
filesizelimit: 900000 # so we can sync with HF spaces
|
9 |
-
|
10 |
-
# Controls when the workflow will run
|
11 |
on:
|
12 |
-
# Triggers the workflow on push or pull request events but only for the main branch
|
13 |
push:
|
14 |
-
branches: [
|
15 |
pull_request:
|
16 |
-
branches: [
|
17 |
|
18 |
-
#
|
19 |
workflow_dispatch:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
name: Sync to Hugging Face hub
|
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
on:
|
|
|
4 |
push:
|
5 |
+
branches: [main]
|
6 |
pull_request:
|
7 |
+
branches: [main]
|
8 |
|
9 |
+
# to run this workflow manually from the Actions tab
|
10 |
workflow_dispatch:
|
11 |
+
|
12 |
+
jobs:
|
13 |
+
sync-to-hub:
|
14 |
+
runs-on: ubuntu-latest
|
15 |
+
steps:
|
16 |
+
- uses: actions/checkout@v2
|
17 |
+
- name: Check large files
|
18 |
+
uses: ActionsDesk/lfs-warning@v2.0
|
19 |
+
with:
|
20 |
+
filesizelimit: 900000 # so we can sync to HF spaces
|
21 |
+
- name: Push to hub
|
22 |
+
env:
|
23 |
+
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
24 |
+
run: git push https://boris:$HF_TOKEN@huggingface.co/spaces/flax-community/dalle-mini main
|