Skip to content

Migrate to pyproject.toml with setuptools_scm for tag-based versionin… #39

Migrate to pyproject.toml with setuptools_scm for tag-based versionin…

Migrate to pyproject.toml with setuptools_scm for tag-based versionin… #39

Workflow file for this run

name: Build Wheel
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.9'
- name: Set Branch Name
run: |
echo "branch_name=${GITHUB_HEAD_REF##*/}" >> $GITHUB_ENV
- name: Check Branch
run: echo "$env.branch_name"
- name: Get Hash
id: hash
run: echo "git_hash=$(git rev-parse --short "$GITHUB_SHA")" >> $GITHUB_ENV
- name: Build wheel
run: |
python -m pip install --upgrade pip
pip install build
python -m build
- name: Upload Wheel Artifact
uses: actions/upload-artifact@v6
with:
name: vecto-wheel-${{ env.branch_name }}-${{ env.git_hash }}
path: dist/*.whl
- name: Upload Dist Directory Artifact
uses: actions/upload-artifact@v6
with:
name: dist-${{ env.branch_name }}-${{ env.git_hash }}
path: dist/