Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- name: Build
shell: bash -l {0}
run: |
conda install -y openturns numpy pytest numpydoc sphinx sphinx-gallery sphinx_rtd_theme pandoc flake8 matplotlib
conda install -y setuptools openturns numpy pytest numpydoc sphinx sphinx-gallery sphinx_rtd_theme pandoc flake8 matplotlib
flake8 --max-line-length=120
python setup.py install
pytest
Expand Down
12 changes: 6 additions & 6 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Get source:

.. code-block:: shell

$ git clone https://www.github.com/sofianehaddad/ottemplatepython.git
$ git clone https://www.github.com/openturns/ottemplatepython.git


The install procedure is performed as follows:
Expand All @@ -45,17 +45,17 @@ To run the tests:

$ pytest

Finally to build the documentation, you should invoke the `build_sphinx` option:
Finally to build the documentation, one of the following option could be used :

.. code-block:: shell

$ python setup.py build_sphinx
$ sphinx-build doc doc/_build
#$ python -m sphinx doc doc_build
$ make html -C doc

This builds the documentation in the `build` folder. Another option is to launch the `make` command:

.. code-block:: shell
This generate the documentation in the `doc/_build` folder.

$ make html -C doc

Help pages
==========
Expand Down
2 changes: 1 addition & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@

# General information about the project.
project = u"ottemplate"
copyright = u"2005-2024 Airbus-EDF-IMACS-ONERA-Phimeca"
copyright = u"2005-2025 Airbus-EDF-IMACS-ONERA-Phimeca"
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
Expand Down
9 changes: 9 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[build-system]
requires = [ "setuptools"]

[project]
name = "ottemplate-python"
version = "0.1"
description = "Template"
readme = "README.rst"
dependencies = [ "numpydoc","sphinx_gallery", "sphinx", "matplotlib", "openturns",]
48 changes: 12 additions & 36 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,50 +11,26 @@
pip install .

"""
import re
import os
from distutils.core import setup
from setuptools import setup, find_packages

from setuptools import find_packages

# Get the version from __init__.py
path = os.path.join(os.path.dirname(__file__), 'ottemplate', '__init__.py')
with open(path) as f:
version_file = f.read()

version = re.search(r"^\s*__version__\s*=\s*['\"]([^'\"]+)['\"]",
version_file, re.M)
if version:
version = version.group(1)
else:
raise RuntimeError("Unable to find version string.")

# Long description
with open("README.rst", "r") as fh:
long_description = fh.read()

setup(

# library name
name='ottemplate',

# code version
version=version,

version="0.1",
# list libraries to be imported
packages=find_packages(),

# Descriptions
description="ottemplate",
long_description=long_description,

# List of dependancies
setup_requires=['pytest-runner'],
description="template for python modules utilizing openturns",
install_requires=['numpy>=1.13',
'openturns'],
tests_require=['pytest'],

# Enable to take into account MANIFEST.in
# include_package_data=True,
license="LGPL"
'openturns',
'matplotlib >= 1.5.1',
"numpydoc",
"sphinx_gallery",
"sphinx",
"matplotlib",
"openturns",
"pytest",
"pytest-runner"],
)
Loading