Ludwig Stumpp commited on
Commit
1f9410c
1 Parent(s): 1265022

Add github actions to upload to hf spaces

Browse files
.github/workflows/check-filesize.yaml ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Check file size
2
+ on: [push]
3
+
4
+ jobs:
5
+ sync-to-hub:
6
+ runs-on: ubuntu-latest
7
+ steps:
8
+ - name: Check large files
9
+ uses: ActionsDesk/lfs-warning@v2.0
10
+ with:
11
+ filesizelimit: 10485760 # this is 10MB so we can sync to HF Spaces
.github/workflows/upload-hf-spaces.yaml ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Sync to Hugging Face hub
2
+ on:
3
+ push:
4
+ branches: [main]
5
+
6
+ # to run this workflow manually from the Actions tab
7
+ workflow_dispatch:
8
+
9
+ env:
10
+ HF_USERNAME: ludwigstumpp
11
+ SPACE_NAME: llm-leaderboard
12
+
13
+ jobs:
14
+ sync-to-hub:
15
+ runs-on: ubuntu-latest
16
+ steps:
17
+ - uses: actions/checkout@v3
18
+ with:
19
+ fetch-depth: 0
20
+ lfs: true
21
+ - name: Push to hub
22
+ env:
23
+ HF_TOKEN: ${{ secrets.HF_TOKEN }}
24
+ run: git push https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/$HF_USERNAME/$SPACE_NAME main