fix: resolve CI/CD issues and add git directory validation
Some checks failed
CI / test (push) Has been cancelled
Some checks failed
CI / test (push) Has been cancelled
- Move CI workflow to correct project subdirectory - Remove incorrect cd commands from workflow - Add .git directory existence check before creating hooks
This commit is contained in:
@@ -11,9 +11,10 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
- name: Set up Python
|
- uses: actions/setup-python@v5
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
with:
|
||||||
python-version: '3.11'
|
python-version: '3.11'
|
||||||
|
|
||||||
@@ -23,34 +24,7 @@ jobs:
|
|||||||
pip install -e ".[dev]"
|
pip install -e ".[dev]"
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: |
|
run: pytest tests/ -v
|
||||||
pytest tests/ -v --cov=src --cov-report=term-missing
|
|
||||||
|
|
||||||
- name: Check linting
|
- name: Run linter
|
||||||
run: |
|
run: ruff check .
|
||||||
pip install ruff
|
|
||||||
ruff check .
|
|
||||||
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: test
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Python
|
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
|
||||||
python-version: '3.11'
|
|
||||||
|
|
||||||
- name: Install build dependencies
|
|
||||||
run: |
|
|
||||||
pip install build
|
|
||||||
|
|
||||||
- name: Build package
|
|
||||||
run: |
|
|
||||||
python -m build
|
|
||||||
|
|
||||||
- name: Verify build
|
|
||||||
run: |
|
|
||||||
pip install dist/*.whl
|
|
||||||
commit-gen --help
|
|
||||||
|
|||||||
Reference in New Issue
Block a user