Skip to content

Commit 52d50ba

Browse files
committed
update makefile
Signed-off-by: Bugen Zhao <[email protected]>
1 parent a61d3b1 commit 52d50ba

File tree

2 files changed

+12
-20
lines changed

2 files changed

+12
-20
lines changed

Makefile

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,20 @@
11
SHELL=/bin/bash
22

33
PROJECT_DIR=.
4-
VENV_DIR=${PROJECT_DIR}/venv
5-
PYTHON3_BIN=${VENV_DIR}/bin/python3
6-
7-
venv-freeze:
8-
$(PYTHON3_BIN) -m pip freeze > ${PROJECT_DIR}/requirements-dev.txt
4+
VENV_DIR=${PROJECT_DIR}/.venv
95

106
cleanup-venv:
117
rm -rf ${VENV_DIR}
128

139
prepare-venv:
14-
python3 -m venv ${VENV_DIR}
15-
source ${VENV_DIR}/bin/activate
16-
$(PYTHON3_BIN) -m pip install -r ${PROJECT_DIR}/requirements-dev.txt
17-
@echo
18-
@echo "=============================================="
19-
@echo 'use the following statements to activate venv:'
20-
@echo
21-
@echo 'source ${VENV_DIR}/bin/activate'
22-
@echo "=============================================="
10+
uv sync
2311

2412
build:
2513
@rm -rf dist/*
26-
source ${VENV_DIR}/bin/activate
27-
hatch build
14+
uv build
2815

2916
publish-test:
30-
source ${VENV_DIR}/bin/activate
31-
$(PYTHON3_BIN) -m twine upload --repository testpypi dist/*
17+
uv publish --index testpypi
3218

3319
publish:
34-
source ${VENV_DIR}/bin/activate
35-
$(PYTHON3_BIN) -m twine upload dist/*
20+
uv publish

pyproject.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,3 +55,10 @@ dev = [
5555
"psycopg2-binary>=2.9.9",
5656
"websocket-client>=1.8.0",
5757
]
58+
59+
60+
[[tool.uv.index]]
61+
name = "testpypi"
62+
url = "https://test.pypi.org/simple/"
63+
publish-url = "https://test.pypi.org/legacy/"
64+
explicit = true

0 commit comments

Comments
 (0)