File tree Expand file tree Collapse file tree 3 files changed +44
-0
lines changed Expand file tree Collapse file tree 3 files changed +44
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Build and release difflib-parser to PyPi
2+
3+ on :
4+ workflow_dispatch :
5+ push :
6+ tags :
7+ - " v*.*.*"
8+
9+ permissions :
10+ contents : write
11+ pull-requests : write
12+ packages : read
13+ issues : read
14+
15+ jobs :
16+ publish :
17+ runs-on : ubuntu-latest
18+
19+ steps :
20+ - name : Checkout repository
21+ uses : actions/checkout@v3
22+
23+ - name : Setup Python
24+ uses : actions/setup-python@v5
25+ with :
26+ python-version : " 3.13"
27+
28+ - name : Install dependencies
29+ run : |
30+ python -m pip install --upgrade pip
31+ pip install -r requirements.txt
32+
33+ - name : Build binary
34+ run : |
35+ echo "__version__ = \"${GITHUB_REF_NAME}\"" > src/difflib_parser/version.py
36+ python -m build
37+
38+ - name : Publish
39+ run : |
40+ python -m twine upload --username "__token__" --password ${{ secrets.PYPI_TOKEN }} --skip-existing --verbose dist/*
Original file line number Diff line number Diff line change @@ -28,3 +28,6 @@ pythonpath = ["src"]
2828
2929[tool .mypy ]
3030mypy_path = " src"
31+
32+ [tool .hatch .version ]
33+ path = " src/difflib_parser/version.py"
Original file line number Diff line number Diff line change 1+ __version__ = "0.0.0"
You can’t perform that action at this time.
0 commit comments