File tree 1 file changed +56
-0
lines changed
1 file changed +56
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : CI/CD Pipeline
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
+ PYTHON_VERSION : ' 3.12'
11
+ HF_USERNAME : ' poscye'
12
+ SPACE_NAME : ' ddg-web-search-chat'
13
+
14
+ jobs :
15
+ # lint-and-test:
16
+ # runs-on: ubuntu-latest
17
+ # steps:
18
+ # - uses: actions/checkout@v3
19
+ # with:
20
+ # fetch-depth: 0
21
+ # lfs: true
22
+
23
+ # - name: Set up Python
24
+ # uses: actions/setup-python@v4
25
+ # with:
26
+ # python-version: ${{ env.PYTHON_VERSION }}
27
+ # cache: 'pip'
28
+
29
+ # - name: Install dependencies
30
+ # run: |
31
+ # python -m pip install --upgrade pip
32
+ # pip install ruff pytest gradio
33
+ # pip install -r requirements.txt
34
+
35
+ # - name: Lint with Ruff
36
+ # run: |
37
+ # pip install ruff
38
+ # ruff check .
39
+ # ruff format --check .
40
+
41
+ # - name: Run tests
42
+ # run: |
43
+ # python -m pytest tests/ -v
44
+
45
+ sync-to-hub :
46
+ runs-on : ubuntu-latest
47
+ if : github.event_name == 'push' && github.ref == 'refs/heads/main'
48
+ steps :
49
+ - uses : actions/checkout@v4
50
+ with :
51
+ fetch-depth : 0
52
+ lfs : true
53
+ - name : Push to hub
54
+ env :
55
+ HF_TOKEN : ${{ secrets.HF_TOKEN }}
56
+ run : git push --force https://${{ env.HF_TOKEN }}:${{ secrets.HF_TOKEN }}@huggingface.co/spaces/${{ env.HF_USERNAME }}/${{ env.SPACE_NAME }} main
You can’t perform that action at this time.
0 commit comments