Skip to content

Commit

Permalink
Merge branch 'main' into feat/refacto_pipeline_first_steps
Browse files Browse the repository at this point in the history
  • Loading branch information
linogaliana committed Oct 17, 2024
2 parents 3db0db3 + 2e38b5f commit f30cd9e
Show file tree
Hide file tree
Showing 4 changed files with 1,120 additions and 911 deletions.
58 changes: 58 additions & 0 deletions .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Upload Python Package

on:
push:
branches:
- 'pypi'

permissions:
contents: read

jobs:
release-build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4 # Ensure actions are pinned properly

- uses: actions/setup-python@v5
with:
python-version: "3.x"

- name: Build release distributions
run: |
python -m pip install build
python -m build
- name: Upload distributions
uses: actions/upload-artifact@v4
with:
name: release-dists
path: dist/

publish:
runs-on: ubuntu-latest

needs:
- release-build

permissions:
id-token: write
contents: read # Added this permission

environment:
name: publish
url: https://pypi.org/p/cartiflette

steps:
- name: Retrieve release distributions
uses: actions/download-artifact@v4
with:
name: release-dists
path: dist/

- name: Publish release distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_PASSWORD }} # Ensure the secret name is correct
5 changes: 5 additions & 0 deletions cartiflette/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
from cartiflette.api import download_from_cartiflette_inner

print("This is an experimental version of cartiflette published on PyPi.")
print("To use the latest stable version, you can install it directly from GitHub with the following command:")
print("pip install git+https://github.com/inseeFrLab/cartiflette.git")


carti_download = download_from_cartiflette_inner

__all__ = ["carti_download"]
Loading

0 comments on commit f30cd9e

Please sign in to comment.