File tree Expand file tree Collapse file tree 1 file changed +58
-0
lines changed
.github/workflows/.github/workflows Expand file tree Collapse file tree 1 file changed +58
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Update release
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*.*.*'
7+ pull_request :
8+ branches :
9+ - main
10+ types :
11+ - labeled
12+ - opened
13+ - edited
14+ - synchronize
15+ - reopened
16+
17+ jobs :
18+ release :
19+ runs-on : ubuntu-latest
20+
21+ steps :
22+ - name : Cache dependencies
23+ id : pip-cache
24+ uses : actions/cache@v4
25+ with :
26+ path : ~/.cache/pip
27+ key : ${{ runner.os }}-pip
28+
29+ - name : Install dependencies
30+ run : |
31+ pip install --upgrade pip
32+ pip install wheel
33+ pip install "packaging>=24.2"
34+
35+ - name : Checkout code
36+ uses : actions/checkout@v3
37+
38+ - name : Build and publish to Test PyPI
39+ if : ${{ (github.ref != 'refs/heads/main') && (github.event.label.name == 'release') }}
40+ env :
41+ TWINE_USERNAME : __token__
42+ TWINE_PASSWORD : ${{ secrets.TEST_PYPI_TOKEN }}
43+ run : |
44+ make dist
45+ ls dist/
46+ tar tvf dist/cebra-*.tar.gz
47+ python3 -m twine upload --repository testpypi dist/*
48+
49+ - name : Build and publish to PyPI
50+ if : ${{ github.event_name == 'push' }}
51+ env :
52+ TWINE_USERNAME : __token__
53+ TWINE_PASSWORD : ${{ secrets.PYPI_TOKEN }}
54+ run : |
55+ make dist
56+ ls dist/
57+ tar tvf dist/dlclibrary-*.tar.gz
58+ python3 -m twine upload dist/*
You can’t perform that action at this time.
0 commit comments