Skip to content

Commit

Permalink
Pyproject merge
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilAppleby committed Nov 6, 2024
2 parents fc5deba + 9763066 commit 8bf1755
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 2 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/pypi.publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries

name: Upload Python Package

# on:
# release:
# types: [published]
on: push

permissions:
contents: read

jobs:
build:
name: Build distribution
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build
- name: Build package
run: python -m build
- name: Store the distribution packages
uses: actions/upload-artifact@v4
with:
name: python-package-distributions
path: dist/

publish-to-pypi:
name: Publish Python distribution to PyPI
needs:
- build
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/carrot-transform
permissions:
id-token: write

steps:
- name: Download all the dists
uses: actions/download-artifact@v4
with:
name: python-package-distributions
path: dist/
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,3 @@ build
*.env
temp
.python-version
workflows
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ requires = ["setuptools", "setuptools-scm"]
build-backend = "setuptools.build_meta"

[project]
name = "carrottransform"
name = "carrot-transform"
version = "0.3.1"
authors = [
{ name="PD Appleby", email="[email protected]" },
Expand Down

0 comments on commit 8bf1755

Please sign in to comment.