Skip to content

Commit

Permalink
chore: replace pip with uv
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Cherng <[email protected]>
  • Loading branch information
jfcherng committed Mar 2, 2024
1 parent 44fc365 commit f10bfc8
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 10 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,14 @@ jobs:
submodules: recursive

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip wheel
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
python -m pip install -U uv
- name: Do linting
run: |
make ci-check
make system-install ci-check
10 changes: 9 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
.PHONY: all
all:

.PHONY: system-install
system-install:
uv pip install --system -r requirements.txt

.PHONY: install
install:
python -m pip install -U pip -r requirements.txt
uv pip install -r requirements.txt

.PHONY: pip-compile
pip-compile:
uv pip compile --upgrade requirements.in -o requirements.txt

.PHONY: ci-check
ci-check:
Expand Down
2 changes: 2 additions & 0 deletions requirements.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
mypy
ruff>=0.2
13 changes: 8 additions & 5 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# This is an implicit value, here for clarity
--index https://pypi.python.org/simple/

mypy
ruff>=0.2
# This file was autogenerated by uv via the following command:
# uv pip compile requirements.in -o requirements.txt
mypy==1.8.0
mypy-extensions==1.0.0
# via mypy
ruff==0.3.0
typing-extensions==4.10.0
# via mypy

0 comments on commit f10bfc8

Please sign in to comment.