Skip to content

Add build dependencies to pyproject.toml #1138

Add build dependencies to pyproject.toml

Add build dependencies to pyproject.toml #1138

Workflow file for this run

name: Publish Python Package to PyPI-Resmi
on:
push:
branches: ["main"]
workflow_dispatch:
jobs:
publish:
name: Publish to PyPI
runs-on: ubuntu-latest
permissions:
id-token: write # Gerekli: OIDC token istemek için
contents: read # Kod deposunu okumak için
steps:
- name: Checkout code
uses: actions/checkout@v7
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.x'
- name: Install build dependencies
run: |
python -m pip install --upgrade pip
pip install build
- name: Build docs
run: |
pip install -r docs/requirements.txt
- name: Clean unnecessary files before build
run: |
echo "🧹 Gereksiz dosyalar temizleniyor..."
find . -type d -name "__pycache__" -exec rm -rf {} + 2>/dev/null || true
find . -name "*.pyc" -delete 2>/dev/null || true
find . -name "*.pyo" -delete 2>/dev/null || true
rm -rf build/ dist/ *.egg-info .pytest_cache .mypy_cache
echo "✅ Temizlik tamamlandı"
- name: Build the package
run: python -m build
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1