Skip to content

Commit

Permalink
Use uv (#366)
Browse files Browse the repository at this point in the history
* Use uv

* Remove trailing whitespace

---------

Co-authored-by: Maciej Bieniek <[email protected]>
  • Loading branch information
bieniu and bieniu authored Feb 22, 2024
1 parent baf6936 commit 79bd073
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ ARG VARIANT="3.11"
FROM mcr.microsoft.com/vscode/devcontainers/python:0-${VARIANT}

COPY requirements*.txt /tmp/pip-tmp/
RUN pip3 --disable-pip-version-check --no-cache-dir install -r /tmp/pip-tmp/requirements-test.txt -r /tmp/pip-tmp/requirements.txt && rm -rf /tmp/pip-tmp
RUN pip --disable-pip-version-check --no-cache-dir install -r /tmp/pip-tmp/requirements-test.txt -r /tmp/pip-tmp/requirements.txt && rm -rf /tmp/pip-tmp

ENV SHELL /bin/bash
8 changes: 4 additions & 4 deletions .github/workflows/pre-commit-update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,18 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.x"

- name: Install pre-commit
run: pip install pre-commit

- name: Run pre-commit autoupdate
run: pre-commit autoupdate

- name: Create Pull Request
uses: peter-evans/[email protected]
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
version=$(python setup.py --version)
echo Version from setup.py: $version
echo "::set-output name=version::$version"
- name: Run Release Drafter
uses: release-drafter/[email protected]
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox tox-gh-actions
pip install uv tox tox-gh-actions tox-uv
- name: Test with tox
run: tox
4 changes: 2 additions & 2 deletions scripts/setup-devcontainer-env.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash

pip3 install --upgrade pip setuptools wheel
pip3 --disable-pip-version-check --no-cache-dir install -r requirements-dev.txt
pip install --upgrade pip setuptools wheel
pip --disable-pip-version-check --no-cache-dir install -r requirements-dev.txt
pre-commit install
9 changes: 6 additions & 3 deletions scripts/setup-local-env.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
#!/bin/bash

python3.11 -m venv venv
PYTHON_VERSION=3.11

python$PYTHON_VERSION -m pip install uv
python$PYTHON_VERSION -m uv venv venv --seed --python=$PYTHON_VERSION
source venv/bin/activate
pip3 install --upgrade pip setuptools wheel
pip3 install -r requirements-dev.txt
pip install uv
uv pip install -r requirements-dev.txt
pre-commit install

0 comments on commit 79bd073

Please sign in to comment.