diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c3a293b..2062add 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-20.04 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v5 diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..7056e0e --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,42 @@ +# 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 + +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by +# separate terms of service, privacy policy, and support +# documentation. + +name: Publish Python 🐍 distributions 📦 to PyPI + +on: + release: + types: [ published ] + +permissions: + contents: read + +jobs: + deploy: + + runs-on: ubuntu-20.04 + environment: PyPi + + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.11' + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install build + - name: Build Python 🐍 packages + run: python -m build + - name: Publish distribution 📦 to PyPI + # Upload packages only on a tagged commit + if: startsWith(github.ref, 'refs/tags') + uses: pypa/gh-action-pypi-publish@release/v1 + with: + user: __token__ + password: ${{ secrets.PYPI_TOKEN }} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 68bc17f..2dc53ca 100644 --- a/.gitignore +++ b/.gitignore @@ -157,4 +157,4 @@ cython_debug/ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore # and can be added to the global gitignore or merged into this file. For a more nuclear # option (not recommended) you can uncomment the following to ignore the entire idea folder. -#.idea/ +.idea/ diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..266e99e --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,7 @@ +Changelog +========= + +v0.1.0 (2023-08-02) +------------------- + +* First release of the project. \ No newline at end of file diff --git a/README.md b/README.md index 373052f..cd23c1f 100644 --- a/README.md +++ b/README.md @@ -5,11 +5,8 @@ for Antares simulator studies. ## Install -The library is not yet released on PyPI, for now you may install it -in your dev environment from sources: ```bash -git clone https://github.com/AntaresSimulatorTeam/antares-timeseries-generation -pip install . +pip install antares-timeseries-generation ``` ## Usage diff --git a/pyproject.toml b/pyproject.toml index a9826db..bbdc21f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "antares-timeseries-generation" -version = "0.0.1" +version = "0.1.0" license = {text="MPL-2.0"} dependencies = [ "numpy", "pandas", "PyYAML" ] classifiers = [ diff --git a/sonar-project.properties b/sonar-project.properties index 92a71df..0261120 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -1,4 +1,4 @@ -sonar.projectVersion=0.0.1 +sonar.projectVersion=0.1.0 sonar.organization=antaressimulatorteam sonar.projectKey=AntaresSimulatorTeam_antares-timeseries-generation sonar.sources=src