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
42 changes: 0 additions & 42 deletions INSTALL

This file was deleted.

2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.21.2
1.21.3
73 changes: 73 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
[build-system]
requires = ["setuptools>=44"]
build-backend = "setuptools.build_meta"

[project]
name = "pymodels"
authors = [ { name = "lnls-fac" }, ]
maintainers = [
{name = "Ana Oliveira", email = "ana.clara@lnls.br"},
{name = "Ximenes Resende", email = "xresende@gmail.com"},
{name = "Fernando H. de Sá", email = "fernandohds564@gmail.com"},
{name = "Murilo Barbosa Alves", email= "alvesb.murilo@gmail.com"}
]
description = "PyModels lattice definitions"
readme = "README.md"
dynamic = ["version", "dependencies"]
requires-python = ">=3.6"
classifiers = [
"Intended Audience :: Science/Research",
"Programming Language :: Python",
"Topic :: Scientific/Engineering",
]
license = "MIT"
license-files= [ "LICENSE", ]

[project.urls]
Homepage = "https://github.com/lnls-fac/pymodels"
Download = "https://github.com/lnls-fac/pymodels"
Repository = "https://github.com/lnls-fac/pymodels.git"
Issues = "https://github.com/lnls-fac/pymodels/issues"

# --- Configurações específicas do Setuptools ---
[tool.setuptools]
include-package-data = true

[tool.setuptools.dynamic]
version = { file = "VERSION" }
dependencies = { file = "requirements.txt" }

[tool.setuptools.package-data]
pymodels = ["VERSION", ]

# --- linter and formatter configurations ---
[tool.ruff]
select = [
"W", "E", "A", "B", "C90", "D", "I002", "N", "F", "G", "ARG", "S", "NPY"]
ignore = [
"D203", "D204", "D213", "D215", "D400", "D401", "D404", "D406", "D407",
"D408", "D409", "D413", "E203", "E226"]
ignore-init-module-imports = true
preview = true
line-length = 79
fix = true

[tool.ruff.extend-per-file-ignores]
"__init__.py" = ["F401", "F821"]

[tool.ruff.format]
skip-magic-trailing-comma = true

[tool.ruff.lint.isort]
split-on-trailing-comma = false
combine-as-imports = true

[tool.isort]
split_on_trailing_comma = false
combine_as_imports = true
combine_star = true
multi_line_output = "HANGING_INDENT"
order_by_type = false

[tool.black]
line-length = 79
4 changes: 4 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
numpy>=1.8
lnls>=0.8
mathphys>=0.7
pyaccel>=0.12
22 changes: 19 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,30 @@
#!/usr/bin/env python-sirius

from setuptools import setup, find_packages
import pathlib
from setuptools import find_packages, setup

with open('VERSION','r') as _f:

def get_abs_path(relative):
return str(pathlib.Path(__file__).parent / relative)


with open(get_abs_path("README.md"), "r") as _f:
_long_description = _f.read().strip()


with open(get_abs_path("VERSION"), "r") as _f:
__version__ = _f.read().strip()


with open(get_abs_path("requirements.txt"), "r") as _f:
_requirements = _f.read().strip().split("\n")

setup(
name='pymodels',
version=__version__,
author='lnls-fac',
description='pyModels lattice definitions',
long_description=_long_description,
url='https://github.com/lnls-fac/pymodels',
download_url='https://github.com/lnls-fac/pymodels',
license='MIT License',
Expand All @@ -19,6 +34,7 @@
'Topic :: Scientific/Engineering'
],
packages=find_packages(),
package_data={'pymodels': ['VERSION','BO_V02A/at_flat_file_M0.txt']},
install_requires=_requirements,
package_data={'pymodels': ['VERSION', ]},
zip_safe=False
)