Skip to content

Commit

Permalink
Ft: upload package (#14)
Browse files Browse the repository at this point in the history
  • Loading branch information
clemens-fricke authored Nov 20, 2023
2 parents 58107c8 + b219370 commit 41c55ec
Show file tree
Hide file tree
Showing 5 changed files with 77 additions and 6 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/build_and_upload_wheels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: pypi upload

on:
push:
branches: ["main", "ft-packaging"]

jobs:
wheel_build_full:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: build wheels and sdist
run: pipx run build

- uses: actions/upload-artifact@v3
with:
path: ./dist/*

upload_pypi:
needs: [wheel_build_full]
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
with:
name: artifact
path: dist

- uses: pypa/[email protected]
with:
skip_existing: true
user: __token__
password: ${{ secrets.PYPI_RELESO }}
32 changes: 32 additions & 0 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the OS, Python version and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.12"
# You can also specify other tool versions:
# nodejs: "19"
# rust: "1.64"
# golang: "1.19"

# Build documentation in the "docs/" directory with Sphinx
sphinx:
configuration: docs/source/conf.py

# Optionally build your docs in additional formats such as PDF and ePub
# formats:
# - pdf
# - epub

# Optional but recommended, declare the Python requirements required
# to build your documentation
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
install:
- requirements: docs/requirements.txt
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ sphinx is installed ignore the first two lines.
The following command line calls create a conda environment with all necessary
dependencies for building the documentation.
``` console
(base) $ conda create -n sphinx python=3.9
(base) $ conda activate sphinx
(sphinx) $ pip install sphinx sphinx-rtd-theme
(base) $ conda create -n sphinx python=3.9
(base) $ conda activate sphinx
(sphinx) $ pip install sphinx sphinx-rtd-theme
```

The documentation is built by executing the following command inside the folder
Expand Down
2 changes: 2 additions & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
sphinx
sphinx-rtd-theme
10 changes: 7 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,13 @@ dependencies = [
"hjson",
]
dynamic = [
"version",
"readme"
"version"
]

[project.readme]
file = "README.md"
content-type = "text/markdown"

[project.optional-dependencies]
all = [
"splinepy[all]"
Expand All @@ -42,6 +45,8 @@ docs = [
[project.scripts]
releso = "releso.__main__:entry"



[tool.setuptools]
packages = [
"releso",
Expand All @@ -54,7 +59,6 @@ build-backend = "setuptools.build_meta"

[tool.setuptools.dynamic]
version = {attr = "releso.__version__.version"}
readme = {file = "README.md"}

[tool.black]
line-length = 79
Expand Down

0 comments on commit 41c55ec

Please sign in to comment.