Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 7 additions & 14 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,26 +16,19 @@ jobs:
- name: Check out the repository
uses: actions/checkout@v3


- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: latest # You can specify a version if needed
virtualenvs-create: true
virtualenvs-in-project: true

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: "3.13"
cache: "poetry"

- name: Poetry install
run: poetry install --with dev
- name: Install dependencies
run: uv sync --group dev

- name: Pre-commit install
run: poetry run pre-commit install
run: uv run pre-commit install

- name: Run pre-commit
run: poetry run pre-commit run --show-diff-on-failure --color=always --all-files
run: uv run pre-commit run --show-diff-on-failure --color=always --all-files
20 changes: 4 additions & 16 deletions .github/workflows/run_tests.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Run Pytest with Poetry
name: Run Pytest

on:
push:
Expand All @@ -20,24 +20,12 @@ jobs:
uses: actions/checkout@v3

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

- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: latest # You can specify a version if needed
virtualenvs-create: true
virtualenvs-in-project: true

- name: Configure Poetry Virtual Environment
run: |
poetry config virtualenvs.create true
poetry config virtualenvs.in-project true

- name: Install Dependencies
run: poetry install --with dev
run: uv sync --group dev

- name: Run Tests
run: poetry run pytest
run: uv run pytest
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ repos:
hooks:
- id: ruff_format
name: ruff_format
entry: poetry run ruff format
entry: uv run ruff format
language: system
types: [python]
files: "^popsim/"
exclude: "^popsim/tests/"
- id: ruff_check
name: ruff_check
entry: poetry run ruff check --fix
entry: uv run ruff check --fix
language: system
types: [python]
files: "^popsim/"
Expand Down
Loading
Loading