diff --git a/as-ap-currinfo/Makefile b/as-ap-currinfo/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-currinfo/Makefile +++ b/as-ap-currinfo/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-currinfo/pyproject.toml b/as-ap-currinfo/pyproject.toml new file mode 100644 index 00000000..b344be32 --- /dev/null +++ b/as-ap-currinfo/pyproject.toml @@ -0,0 +1,83 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_currinfo" +authors = [{ name = "lnls-sirius" } ] +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 = "Soft IOC for Electron Beam Current Informations." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-li-ap-currinfo.py", + "scripts/sirius-ioc-ts-ap-currinfo.py", + "scripts/sirius-ioc-bo-ap-currinfo.py", + "scripts/sirius-ioc-si-ap-currinfo.py", + "scripts/sirius-ioc-si-ap-currinfo-lifetime.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_currinfo = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ap-injctrl/Makefile b/as-ap-injctrl/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-injctrl/Makefile +++ b/as-ap-injctrl/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-injctrl/pyproject.toml b/as-ap-injctrl/pyproject.toml new file mode 100644 index 00000000..b4443d74 --- /dev/null +++ b/as-ap-injctrl/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_injctrl" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for High Level Control of Injection Procedure." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-ap-injctrl.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_injctrl = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ap-machshift/Makefile b/as-ap-machshift/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-machshift/Makefile +++ b/as-ap-machshift/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-machshift/pyproject.toml b/as-ap-machshift/pyproject.toml new file mode 100644 index 00000000..c4d726b9 --- /dev/null +++ b/as-ap-machshift/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_machshift" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for High Level Control of Machine Shifts." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-ap-machshift.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_machshift = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ap-opmode/Makefile b/as-ap-opmode/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-opmode/Makefile +++ b/as-ap-opmode/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-opmode/pyproject.toml b/as-ap-opmode/pyproject.toml new file mode 100644 index 00000000..80a8c901 --- /dev/null +++ b/as-ap-opmode/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_opmode" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for Accelerator Operation Mode." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-ap-opmode.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_opmode = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ap-opticscorr/Makefile b/as-ap-opticscorr/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-opticscorr/Makefile +++ b/as-ap-opticscorr/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-opticscorr/pyproject.toml b/as-ap-opticscorr/pyproject.toml new file mode 100644 index 00000000..8e42403c --- /dev/null +++ b/as-ap-opticscorr/pyproject.toml @@ -0,0 +1,82 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_opticscorr" +authors = [{ name = "lnls-sirius" } ] +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 = "IOCs for High Level Control Tune and Chromaticity Correction." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-bo-ap-tunecorr.py", + "scripts/sirius-ioc-bo-ap-chromcorr.py", + "scripts/sirius-ioc-si-ap-tunecorr.py", + "scripts/sirius-ioc-si-ap-chromcorr.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_opticscorr = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ap-posang/Makefile b/as-ap-posang/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-posang/Makefile +++ b/as-ap-posang/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-posang/pyproject.toml b/as-ap-posang/pyproject.toml new file mode 100644 index 00000000..35ccd984 --- /dev/null +++ b/as-ap-posang/pyproject.toml @@ -0,0 +1,80 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_posang" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for High Level Control of Injection Position and Angle." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-tb-ap-posang.py", + "scripts/sirius-ioc-ts-ap-posang.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_posang = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ap-sofb/Makefile b/as-ap-sofb/Makefile index 521ec1cf..994be514 100644 --- a/as-ap-sofb/Makefile +++ b/as-ap-sofb/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ap-sofb/pyproject.toml b/as-ap-sofb/pyproject.toml new file mode 100644 index 00000000..e438d5f3 --- /dev/null +++ b/as-ap-sofb/pyproject.toml @@ -0,0 +1,82 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ap_sofb" +authors = [{ name = "lnls-sirius" } ] +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 = "Slow Orbit Feedback System for Sirius" +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-ap-sofb.py", + "scripts/sirius-ioc-bo-ap-sofb.py", + "scripts/sirius-ioc-tb-ap-sofb.py", + "scripts/sirius-ioc-ts-ap-sofb.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ap_sofb = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ps-diag/Makefile b/as-ps-diag/Makefile index 521ec1cf..994be514 100644 --- a/as-ps-diag/Makefile +++ b/as-ps-diag/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ps-diag/pyproject.toml b/as-ps-diag/pyproject.toml new file mode 100644 index 00000000..ada8266d --- /dev/null +++ b/as-ps-diag/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ps_diag" +authors = [{ name = "lnls-sirius" } ] +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 = "Power Supply Current SP/Mon diagnostics" +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-ps-diag.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ps_diag = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ps/Makefile b/as-ps/Makefile index 521ec1cf..994be514 100644 --- a/as-ps/Makefile +++ b/as-ps/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ps/pyproject.toml b/as-ps/pyproject.toml new file mode 100644 index 00000000..e1fafe59 --- /dev/null +++ b/as-ps/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ps" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for Power Supplies." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-ps.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ps = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-pu-conv/Makefile b/as-pu-conv/Makefile index 521ec1cf..994be514 100644 --- a/as-pu-conv/Makefile +++ b/as-pu-conv/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-pu-conv/pyproject.toml b/as-pu-conv/pyproject.toml new file mode 100644 index 00000000..06e46438 --- /dev/null +++ b/as-pu-conv/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_pu_conv" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC Conv for Pulse Power Supplies." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-pu-conv.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_pu_conv = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-pu-diag/Makefile b/as-pu-diag/Makefile index 521ec1cf..994be514 100644 --- a/as-pu-diag/Makefile +++ b/as-pu-diag/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-pu-diag/pyproject.toml b/as-pu-diag/pyproject.toml new file mode 100644 index 00000000..0485198c --- /dev/null +++ b/as-pu-diag/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_pu_diag" +authors = [{ name = "lnls-sirius" } ] +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 = "Pulsed Power Supply diagnostics" +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-pu-diag.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_pu_diag = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-rf-diag/Makefile b/as-rf-diag/Makefile index 521ec1cf..994be514 100644 --- a/as-rf-diag/Makefile +++ b/as-rf-diag/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-rf-diag/pyproject.toml b/as-rf-diag/pyproject.toml new file mode 100644 index 00000000..82159e8e --- /dev/null +++ b/as-rf-diag/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_rf_diag" +authors = [{ name = "lnls-sirius" } ] +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 = "RF diagnostics" +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-rf-diag.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_rf_diag = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/as-ti-control/Makefile b/as-ti-control/Makefile index 521ec1cf..994be514 100644 --- a/as-ti-control/Makefile +++ b/as-ti-control/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/as-ti-control/pyproject.toml b/as-ti-control/pyproject.toml new file mode 100644 index 00000000..2cab2f13 --- /dev/null +++ b/as-ti-control/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "as_ti_control" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for High Level control of Sirius Timing System." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-as-ti-control.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +as_ti_control = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/bl-ap-imgproc/Makefile b/bl-ap-imgproc/Makefile index 521ec1cf..994be514 100644 --- a/bl-ap-imgproc/Makefile +++ b/bl-ap-imgproc/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/bl-ap-imgproc/pyproject.toml b/bl-ap-imgproc/pyproject.toml new file mode 100644 index 00000000..b6e2eb4b --- /dev/null +++ b/bl-ap-imgproc/pyproject.toml @@ -0,0 +1,80 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "bl_ap_imgproc" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for DVF Beamline image processing." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-bl-ap-imgproc-caxdvf1.py", + "scripts/sirius-ioc-bl-ap-imgproc-caxdvf2.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +bl_ap_imgproc = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/li-ap-diag/Makefile b/li-ap-diag/Makefile index 521ec1cf..994be514 100644 --- a/li-ap-diag/Makefile +++ b/li-ap-diag/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/li-ap-diag/pyproject.toml b/li-ap-diag/pyproject.toml new file mode 100644 index 00000000..6c91d2dc --- /dev/null +++ b/li-ap-diag/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "li_ap_diag" +authors = [{ name = "lnls-sirius" } ] +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 = "Linac diagnostics" +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-li-ap-diag.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +li_ap_diag = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/li-ap-energy/Makefile b/li-ap-energy/Makefile index 521ec1cf..994be514 100644 --- a/li-ap-energy/Makefile +++ b/li-ap-energy/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/li-ap-energy/pyproject.toml b/li-ap-energy/pyproject.toml new file mode 100644 index 00000000..a9b0508a --- /dev/null +++ b/li-ap-energy/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "li_ap_energy" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for Linac Energy measurement for Sirius." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-li-ap-energy.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +li_ap_energy = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/li-ps-conv/Makefile b/li-ps-conv/Makefile index 521ec1cf..994be514 100644 --- a/li-ps-conv/Makefile +++ b/li-ps-conv/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/li-ps-conv/pyproject.toml b/li-ps-conv/pyproject.toml new file mode 100644 index 00000000..a2e9ce77 --- /dev/null +++ b/li-ps-conv/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "li_ps_conv" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC Conv for Linac Power Supplies." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-li-ps-conv.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +li_ps_conv = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/pcaspy-template-generator/project-name/LICENSE b/pcaspy-template-generator/project-name/LICENSE new file mode 120000 index 00000000..30cff740 --- /dev/null +++ b/pcaspy-template-generator/project-name/LICENSE @@ -0,0 +1 @@ +../../LICENSE \ No newline at end of file diff --git a/pcaspy-template-generator/project-name/MANIFEST.in b/pcaspy-template-generator/project-name/MANIFEST.in new file mode 100644 index 00000000..b2eca7e2 --- /dev/null +++ b/pcaspy-template-generator/project-name/MANIFEST.in @@ -0,0 +1 @@ +include py_project_name/access_rules.as diff --git a/pcaspy-template-generator/project-name/Makefile b/pcaspy-template-generator/project-name/Makefile new file mode 100644 index 00000000..994be514 --- /dev/null +++ b/pcaspy-template-generator/project-name/Makefile @@ -0,0 +1,20 @@ +PACKAGE:=$(shell basename $(shell pwd)) +PREFIX ?= +PIP ?= pip +ifeq ($(CONDA_PREFIX),) + PREFIX=sudo -H + PIP=pip-sirius +endif + +install: uninstall + $(PREFIX) $(PIP) install --no-deps ./ + $(PREFIX) git clean -fdX + +uninstall: + $(PREFIX) $(PIP) uninstall -y $(PACKAGE) + +develop-install: develop-uninstall + $(PIP) install --no-deps -e ./ + +develop-uninstall: + $(PIP) uninstall -y $(PACKAGE) diff --git a/pcaspy-template-generator/project-name/README.md b/pcaspy-template-generator/project-name/README.md new file mode 100644 index 00000000..9a30223c --- /dev/null +++ b/pcaspy-template-generator/project-name/README.md @@ -0,0 +1,12 @@ +# IOC +This IOC does some stuff. + +## Installation +`make install` +`make develop-install` + +## Dependencies +dev-packages + +## Running +`sirius-ioc-project-name.py` diff --git a/pcaspy-template-generator/project-name/VERSION b/pcaspy-template-generator/project-name/VERSION new file mode 120000 index 00000000..558194c5 --- /dev/null +++ b/pcaspy-template-generator/project-name/VERSION @@ -0,0 +1 @@ +../../VERSION \ No newline at end of file diff --git a/pcaspy-template-generator/project-name/py_project_name/access_rules.as b/pcaspy-template-generator/project-name/py_project_name/access_rules.as new file mode 100644 index 00000000..8beb4c75 --- /dev/null +++ b/pcaspy-template-generator/project-name/py_project_name/access_rules.as @@ -0,0 +1,4 @@ +ASG(rbpv) { + RULE(1, READ) + RULE(0, WRITE) +} diff --git a/pcaspy-template-generator/project-name/py_project_name/csdev.py b/pcaspy-template-generator/project-name/py_project_name/csdev.py new file mode 100644 index 00000000..a10c5d0a --- /dev/null +++ b/pcaspy-template-generator/project-name/py_project_name/csdev.py @@ -0,0 +1,29 @@ +"""PVs definition for the IOC.""" + +from siriuspy import csdev as _csdev + + +class Const(_csdev.Const): + """Const class.""" + _register = _csdev.Const.register + + DisconnConn = _register("DisconnConn", _csdev.ETypes.DISCONN_CONN) + + +pvs_database = { + + 'Version-Cte': {'type': 'str', 'value': 'UNDEF'}, + 'TimestampBoot-Cte': { + 'type': 'float', 'value': 0, + 'prec': 7, 'unit': 'timestamp'}, + 'TimestampUpdate-Mon': { + 'type': 'float', 'value': 0, + 'prec': 7, 'unit': 'timestamp'}, + 'Log-Mon': {'type': 'str', 'value': 'Starting...'}, + 'ConnStatus-Mon': { + 'type': 'enum', 'value': Const.DisconnConn.Disconnected, + 'enums': _csdev.ETypes.DISCONN_CONN, + 'unit': 'DisconnConn', + }, + +} diff --git a/pcaspy-template-generator/project-name/py_project_name/main.py b/pcaspy-template-generator/project-name/py_project_name/main.py new file mode 100644 index 00000000..ca3685d0 --- /dev/null +++ b/pcaspy-template-generator/project-name/py_project_name/main.py @@ -0,0 +1,93 @@ +"""Main Module of the IOC Logic.""" + +import logging as _log +import time as _time + +import epics as _epics +from siriuspy.callbacks import Callback as _Callback +from siriuspy.devices import DeviceSet as _DeviceSet + +from . import csdev as _csdev + + +class App(_DeviceSet, _Callback): + """Main Class of the IOC Logic.""" + + SCAN_FREQUENCY = 1 # [Hz] + + def __init__(self, driver=None): + """Initialize the instance.""" + _Callback.__init__(self) + + self.driver = driver + devs = tuple() + _DeviceSet.__init__(self, devices=devs) + + self._pvs_database = _csdev.pvs_database + # use pyepics recommendations for threading + _epics.ca.use_initial_context() + + # status scanning + self.quit = False + self.scanning = False + self.thread_check_conns = _epics.ca.CAThread( + target=self._run_updates, daemon=True) + self.thread_check_conns.start() + + def init_database(self): + """Set initial PV values.""" + pvn2vals = { + 'TimestampUpdate-Mon': _time.time(), + 'Log-Mon': 'Started.', + } + for pvn, val in pvn2vals.items(): + self.run_callbacks(pvn, val) + + @property + def pvs_database(self): + """Return pvs_database.""" + return self._pvs_database + + def process(self, interval): + """Sleep.""" + _time.sleep(interval) + + def read(self, reason): + """Read PV from database.""" + # implementation here + # The default behavior is to return None and let the driver read + # from the database. + value = None + return value + + def write(self, reason, value): + """Write PV in the model.""" + # implementation here + # this should be used in case PV state change. + return True # return True for successful write and False otherwise. + + def _run_updates(self): + # scan + tplanned = 1.0 / App.SCAN_FREQUENCY + while not self.quit: + if not self.scanning: + _time.sleep(tplanned) + continue + + _t0 = _time.time() + + # update sections status + self.run_callbacks('TimestampUpdate-Mon', _time.time()) + self.run_callbacks('ConnStatus-Mon', self.connected) + + # time mgmnt + ttook = _time.time() - _t0 + tsleep = tplanned - ttook + if tsleep > 0: + _time.sleep(tsleep) + else: + logstr = ( + 'Connections check took more than planned... ' + '{0:.3f}/{1:.3f} s'.format(ttook, tplanned) + ) + _log.warning(logstr) diff --git a/pcaspy-template-generator/project-name/py_project_name/py_project_name.py b/pcaspy-template-generator/project-name/py_project_name/py_project_name.py new file mode 100755 index 00000000..402322bb --- /dev/null +++ b/pcaspy-template-generator/project-name/py_project_name/py_project_name.py @@ -0,0 +1,126 @@ +#!/usr/bin/env python-sirius +""".""" + +import logging as _log +import os as _os +import signal as _signal +import sys as _sys +import time as _time + +import pcaspy as _pcaspy +import pcaspy.tools as _pcaspy_tools +from siriuspy import util as _util +from siriuspy.envars import VACA_PREFIX as _VACA_PREFIX + +from .main import App as _App + +INTERVAL = 0.1 +STOP_EVENT = False + +IOC_PREFIX = 'AS-Glob:AP-DEVICE:' +IOC_NAME = 'AS-AP-DEVICE' + + +def _stop_now(signum, frame): + _ = frame + sname = _signal.Signals(signum).name + tstamp = _util.get_timestamp() + strf = f'{sname} received at {tstamp}' + _log.warning(strf) + _sys.stdout.flush() + _sys.stderr.flush() + global STOP_EVENT + STOP_EVENT = True + + +def _attribute_access_security_group(server, dbase): + for k, val in dbase.items(): + if k.endswith(('-RB', '-Sts', '-Cte', '-Mon')): + val.update({'asg': 'rbpv'}) + path_ = _os.path.abspath(_os.path.dirname(__file__)) + server.initAccessSecurityFile(path_ + '/access_rules.as') + + +class _PCASDriver(_pcaspy.Driver): + + def __init__(self, app): + super().__init__() + self.app = app + self.app.driver = self + self.app.add_callback(self.update_pv) + + def read(self, reason): + value = self.app.read(reason) + if value is None: + return super().read(reason) + else: + return value + + def write(self, reason, value): + ret_val = self.app.write(reason, value) + if reason.endswith('-Cmd'): + value = self.getParam(reason) + 1 + if ret_val: + return super().write(reason, value) + return False + + def update_pv(self, pvname, value, **kwargs): + """Update PV.""" + _ = kwargs + self.setParam(pvname, value) + self.updatePV(pvname) + + +def run(): + """Run the IOC.""" + # define abort function + _signal.signal(_signal.SIGINT, _stop_now) + _signal.signal(_signal.SIGTERM, _stop_now) + + # configure log file + _util.configure_log_file() + + # define IOC, init pvs database and create app object + _version = _util.get_last_commit_hash() + _ioc_prefix = _VACA_PREFIX + ('-' if _VACA_PREFIX else '') + _ioc_prefix += IOC_PREFIX + app = _App() + dbase = app.pvs_database + dbase['Version-Cte']['value'] = _version + dbase['TimestampBoot-Cte']['value'] = _time.time() + + # check if another IOC is running + pvname = _ioc_prefix + next(iter(dbase)) + if _util.check_pv_online(pvname, use_prefix=False): + raise ValueError('Another instance of this IOC is already running!') + + # check if another IOC is running + _util.print_ioc_banner( + ioc_name=IOC_NAME, + db=dbase, + description=IOC_NAME + ' Soft IOC', + version=_version, + prefix=_ioc_prefix) + + # create a new simple pcaspy server and driver to respond client's requests + server = _pcaspy.SimpleServer() + _attribute_access_security_group(server, dbase) + server.createPV(_ioc_prefix, dbase) + driver = _PCASDriver(app) + app.init_database() + + # initiate a new thread responsible for listening for client connections + server_thread = _pcaspy_tools.ServerThread(server) + server_thread.start() + + # main loop + driver.app.scanning = True + while not STOP_EVENT: + driver.app.process(INTERVAL) + + driver.app.scanning = False + driver.app.quit = True + + # sends stop signal to server thread + server_thread.stop() + server_thread.join() diff --git a/pcaspy-template-generator/project-name/pyproject.toml b/pcaspy-template-generator/project-name/pyproject.toml new file mode 100644 index 00000000..9bed3ade --- /dev/null +++ b/pcaspy-template-generator/project-name/pyproject.toml @@ -0,0 +1,77 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "py_project_name" +authors = [{ name = "lnls-sirius" } ] +maintainers = [ + {name = "maintainder1", email = "maintainder1@email.br"}, + {name = "maintainder2", email = "maintainder2@email.com"}, +] +description = "PROJECT-DESCRIPTION" +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [project.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-project-name.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +py_project_name = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/pcaspy-template-generator/project-name/requirements.txt b/pcaspy-template-generator/project-name/requirements.txt new file mode 120000 index 00000000..fd1efae7 --- /dev/null +++ b/pcaspy-template-generator/project-name/requirements.txt @@ -0,0 +1 @@ +../../requirements.txt \ No newline at end of file diff --git a/pcaspy-template-generator/project-name/scripts/sirius-ioc-project-name.py b/pcaspy-template-generator/project-name/scripts/sirius-ioc-project-name.py new file mode 100644 index 00000000..9a21b2a9 --- /dev/null +++ b/pcaspy-template-generator/project-name/scripts/sirius-ioc-project-name.py @@ -0,0 +1,8 @@ +#!/usr/bin/env python-sirius +"""Script for the IOC.""" + +from py_project_name import py_project_name + + +if __name__ == '__main__': + py_project_name.run(False) diff --git a/pcaspy-template-generator/project-name/setup.py b/pcaspy-template-generator/project-name/setup.py new file mode 100755 index 00000000..a679e26d --- /dev/null +++ b/pcaspy-template-generator/project-name/setup.py @@ -0,0 +1,33 @@ +#!/usr/bin/env python3 + +from setuptools import setup + +with open('VERSION', 'r') as _f: + __version__ = _f.read().strip() + +with open('README.md', 'r') as _f: + _long_description = _f.read().strip() + +with open('requirements.txt', 'r') as _f: + _requirements = _f.read().strip().split('\n') + +setup( + name='py_project_name', + version=__version__, + author='lnls-sirius', + description='PROJECT-DESCRIPTION', + long_description=_long_description, + url='https://github.com/lnls-sirius/machine-applications', + download_url='https://github.com/lnls-sirius/machine-applications', + license="GPL-3.0", + classifiers=[ + 'Intended Audience :: Science/Research', + 'Programming Language :: Python', + 'Topic :: Scientific/Engineering' + ], + packages=['py_project_name'], + install_requires=_requirements, + package_data={'py_project_name': ['VERSION']}, + scripts=[], + zip_safe=False +) diff --git a/pcaspy-template-generator/sirius-instantiate-pcaspy-template.py b/pcaspy-template-generator/sirius-instantiate-pcaspy-template.py deleted file mode 100755 index 1c711607..00000000 --- a/pcaspy-template-generator/sirius-instantiate-pcaspy-template.py +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/env python3 - -import os -import sys - -if __name__ == '__main__': - - if len(sys.argv) != 2: - raise Exception('invalid number of arguments!') - sys.exit(1); - - project = sys.argv[1] - if os.path.exists(project): - raise Exception('directory already exists!') - - os.system('cp -rf --preserve=mode template_files ' + project) - os.rename(os.path.join(project, 'pcaspy-template'), os.path.join(project, project)) - os.rename(os.path.join(project, project, 'run.py'), os.path.join(project, project, project+'.py')) - os.system('cd ' + project + '; ln -s ' + os.path.join(project,'VERSION')) diff --git a/pcaspy-template-generator/sirius-instantiate-pcaspy-template.sh b/pcaspy-template-generator/sirius-instantiate-pcaspy-template.sh new file mode 100755 index 00000000..c75588a7 --- /dev/null +++ b/pcaspy-template-generator/sirius-instantiate-pcaspy-template.sh @@ -0,0 +1,60 @@ +#!/usr/bin/env bash + +# This code was done by free version ChatGPT o4.mini in 2025/06/09. + +set -e # Faz o script parar em caso de erro + +# check number of arguments. +if [ "$#" -ne 1 ]; then + echo "invalid number of arguments!" >&2 + exit 1 +fi + +# argument must be the relative path from this folder to the ioc folder +# preferably the IOC name must be
--, +# just like the other existing IOCS. +project_path="$1" +project="$(basename "$project_path")" + +# the python project name will be:
__: +pyproject="${project//-/_}" + +if [ -d "$project_path" ] && [ "$(ls -A "$project_path")" ]; then + echo "directory already exists and is not empty!" >&2 + exit 1 +fi + +src_abs_path="$(realpath project-name)" +dest_abs_path="$(realpath "$project_path")" + +mkdir -p "$project_path" + +# Copy all files, including links (this will break the links): +cp -a "$src_abs_path"/. "$dest_abs_path"/ + +# Fix relative symbolic links so that they work in the new structure: +find "$dest_abs_path" -type l | while read -r link; do + target="$(readlink "$link")" + if [[ "$target" == /* ]]; then + # If enter here, it means the link has absolute path. nothing to do. + continue + fi + link_dir="$(dirname "$link")" + abs_target="$(realpath -m "$src_abs_path/$target")" + new_rel_target="$(realpath --relative-to="$link_dir" "$abs_target")" + ln -sf "$new_rel_target" "$link" +done + +cd "$project_path" + +# start changing file names and content of files to the appropriate name. +mv "py_project_name" "$pyproject" + +find . -type f ! -xtype l -exec sed -i "s/py_project_name/$pyproject/g" {} + +find . -type f ! -xtype l -exec sed -i "s/project-name/$project/g" {} + + +cd "$pyproject" +mv "py_project_name.py" "${pyproject}.py" + +cd "../scripts" +mv "sirius-ioc-project-name.py" "sirius-ioc-${project}.py" diff --git a/pcaspy-template-generator/template_files/pcaspy-template/VERSION b/pcaspy-template-generator/template_files/pcaspy-template/VERSION deleted file mode 100644 index 8acdd82b..00000000 --- a/pcaspy-template-generator/template_files/pcaspy-template/VERSION +++ /dev/null @@ -1 +0,0 @@ -0.0.1 diff --git a/pcaspy-template-generator/template_files/pcaspy-template/main.py b/pcaspy-template-generator/template_files/pcaspy-template/main.py deleted file mode 100644 index 7bf98712..00000000 --- a/pcaspy-template-generator/template_files/pcaspy-template/main.py +++ /dev/null @@ -1,50 +0,0 @@ -"""Main Module of the IOC Logic.""" - -import pvs as _pvs -import time as _time - -__version__ = _pvs.__version__ - - -class App: - """Main Class of the IOC Logic.""" - - pvs_database = _pvs.pvs_database - - def get_database(self): - """Get the database.""" - db = dict() - for pre, pvs in self.pvs_database.items(): - for pvname, info in pvs.items(): - db[pre + pvname] = info - return db - - def __init__(self, driver=None): - """Initialize the instance.""" - self._driver = driver - - @property - def driver(self): - """Set the driver of the App.""" - return self._driver - - @driver.setter - def driver(self, driver): - self._driver = driver - - def process(self, interval): - """Trigger connection to external PVs in other classes.""" - _time.sleep(interval) - - def read(self, reason): - """Read PV from database.""" - # implementation here - # The default behavior is to return None and let the driver read - # from the database. - return None - - def write(self, reason, value): - """Write PV in the model.""" - # implementation here - # this should be used in case PV state change. - return True # return True for successful write and False otherwise. diff --git a/pcaspy-template-generator/template_files/pcaspy-template/pvs.py b/pcaspy-template-generator/template_files/pcaspy-template/pvs.py deleted file mode 100644 index 358d3265..00000000 --- a/pcaspy-template-generator/template_files/pcaspy-template/pvs.py +++ /dev/null @@ -1,14 +0,0 @@ -"""PVs definition for the IOC.""" - -with open('VERSION', 'r') as _f: - __version__ = _f.read().strip() - -pvs_database = {} - -pvs_database['TEST-'] = { - - 'Version-Cte': {'type': 'string', 'value': __version__}, - - 'PV1': {'type': 'float', 'value': 1.200, 'prec': 3, 'unit': 'm'}, - 'PV2': {'type': 'string', 'value': 'test'}, -} diff --git a/pcaspy-template-generator/template_files/pcaspy-template/run.py b/pcaspy-template-generator/template_files/pcaspy-template/run.py deleted file mode 100755 index 79642b70..00000000 --- a/pcaspy-template-generator/template_files/pcaspy-template/run.py +++ /dev/null @@ -1,76 +0,0 @@ -#!/usr/bin/env python-sirius - -import pcaspy as _pcaspy -import pcaspy.tools as _pcaspy_tools -import signal as _signal -import main as _main - - -INTERVAL = 0.1 -stop_event = False -PREFIX = '' - - -def _stop_now(signum, frame): - print(' - SIGNAL received.') - global stop_event - stop_event = True - - -class _PCASDriver(_pcaspy.Driver): - - def __init__(self, app=None): - super().__init__() - self.app = app or _main.App() - self.app.driver = self - - def read(self, reason): - value = self.app.read(reason) - if value is None: - return super().read(reason) - else: - return value - - def write(self, reason, value): - app_ret = self.app.write(reason, value) - if app_ret: - self.setParam(reason, value) - self.updatePVs() - return app_ret - - -def run(): - """Run the IOC.""" - # define abort function - _signal.signal(_signal.SIGINT, _stop_now) - _signal.signal(_signal.SIGTERM, _stop_now) - - # create the application model - app = _main.App() - - db = app.get_database() - - # create a new simple pcaspy server and driver to respond client's requests - server = _pcaspy.SimpleServer() - server.createPV(PREFIX, db) - - # create the driver - pcas_driver = _PCASDriver(app) - - # initiate a new thread responsible for listening for client connections - server_thread = _pcaspy_tools.ServerThread(server) - server_thread.start() - - # main loop - # while not stop_event.is_set(): - while not stop_event: - pcas_driver.app.process(INTERVAL) - - print('exiting...') - # send stop signal to server thread - server_thread.stop() - server_thread.join() - - -if __name__ == '__main__': - run() diff --git a/pcaspy-template-generator/template_files/setup.py b/pcaspy-template-generator/template_files/setup.py deleted file mode 100755 index 259b536a..00000000 --- a/pcaspy-template-generator/template_files/setup.py +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env python3 - -from setuptools import setup - -with open('VERSION','r') as _f: - __version__ = _f.read().strip() - -setup( - name='PROJECT-NAME', - version=__version__, - author='lnls-sirius', - description='PROJECT-DESCRIPTION', - url='PROJECT-URL', - download_url='PROJECT-DOWNLOAD-URL', - license='MIT License', - classifiers=[ - 'Intended Audience :: Science/Research', - 'Programming Language :: Python', - 'Topic :: Scientific/Engineering' - ], - packages=['PROJECT-NAME'], - package_data={'PROJECT-NAME': ['VERSION']}, - scripts=[], - zip_safe=False -) diff --git a/si-ap-fofb/Makefile b/si-ap-fofb/Makefile index 521ec1cf..994be514 100644 --- a/si-ap-fofb/Makefile +++ b/si-ap-fofb/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-ap-fofb/pyproject.toml b/si-ap-fofb/pyproject.toml new file mode 100644 index 00000000..0bcc1d66 --- /dev/null +++ b/si-ap-fofb/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_ap_fofb" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for High Level FOFB Control." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-ap-fofb.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_ap_fofb = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/si-ap-idff/Makefile b/si-ap-idff/Makefile index 521ec1cf..994be514 100644 --- a/si-ap-idff/Makefile +++ b/si-ap-idff/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-ap-idff/pyproject.toml b/si-ap-idff/pyproject.toml new file mode 100644 index 00000000..8c182479 --- /dev/null +++ b/si-ap-idff/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_ap_idff" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for ID feedforward." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-ap-idff.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_ap_idff = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/si-ap-orbintlk/Makefile b/si-ap-orbintlk/Makefile index 521ec1cf..994be514 100644 --- a/si-ap-orbintlk/Makefile +++ b/si-ap-orbintlk/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-ap-orbintlk/pyproject.toml b/si-ap-orbintlk/pyproject.toml new file mode 100644 index 00000000..05bbe492 --- /dev/null +++ b/si-ap-orbintlk/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_ap_orbintlk" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for Global Orbit Interlock Control." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-ap-orbintlk.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_ap_orbintlk = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/si-ap-stabinfo/Makefile b/si-ap-stabinfo/Makefile index 521ec1cf..994be514 100644 --- a/si-ap-stabinfo/Makefile +++ b/si-ap-stabinfo/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-ap-stabinfo/pyproject.toml b/si-ap-stabinfo/pyproject.toml new file mode 100644 index 00000000..78e2d18a --- /dev/null +++ b/si-ap-stabinfo/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_ap_stabinfo" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for beam stability indicators." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-ap-stabinfo.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_ap_stabinfo = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/si-di-fpmosc/Makefile b/si-di-fpmosc/Makefile index 521ec1cf..994be514 100644 --- a/si-di-fpmosc/Makefile +++ b/si-di-fpmosc/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-di-fpmosc/pyproject.toml b/si-di-fpmosc/pyproject.toml new file mode 100644 index 00000000..52ddea2b --- /dev/null +++ b/si-di-fpmosc/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_di_fpmosc" +authors = [{ name = "lnls-sirius" } ] +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 = "Soft IOC for Electron Beam Filling Pattern Informations." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-di-fpmosc.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_di_fpmosc = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/si-id-conv/Makefile b/si-id-conv/Makefile index 521ec1cf..994be514 100644 --- a/si-id-conv/Makefile +++ b/si-id-conv/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-id-conv/pyproject.toml b/si-id-conv/pyproject.toml new file mode 100644 index 00000000..fbdb80f7 --- /dev/null +++ b/si-id-conv/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_id_conv" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC Conv for Insertion Devices." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-id-conv.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_id_conv = [ "VERSION",] + +# --- linter e formatter --- +[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 diff --git a/si-id-epu50/Makefile b/si-id-epu50/Makefile index 521ec1cf..994be514 100644 --- a/si-id-epu50/Makefile +++ b/si-id-epu50/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-id-epu50/pyproject.toml b/si-id-epu50/pyproject.toml new file mode 100644 index 00000000..7dcaeee0 --- /dev/null +++ b/si-id-epu50/pyproject.toml @@ -0,0 +1,82 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_id_epu50" +authors = [{ name = "lnls-sirius" } ] +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 = "IOC for EPU50 Insertion Device." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-id-epu50.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_id_epu50 = [ "VERSION", + "config/config.toml", + "config/drive_messages.yaml", + "config/autosave_epu.req",] + +# --- linter e formatter --- +[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 diff --git a/si-ps-conv-fastcorrs/Makefile b/si-ps-conv-fastcorrs/Makefile index 521ec1cf..994be514 100644 --- a/si-ps-conv-fastcorrs/Makefile +++ b/si-ps-conv-fastcorrs/Makefile @@ -16,7 +16,5 @@ uninstall: develop-install: develop-uninstall $(PIP) install --no-deps -e ./ -# known issue: It will fail to uninstall scripts -# if they were installed in develop mode develop-uninstall: $(PIP) uninstall -y $(PACKAGE) diff --git a/si-ps-conv-fastcorrs/pyproject.toml b/si-ps-conv-fastcorrs/pyproject.toml new file mode 100644 index 00000000..c597d09b --- /dev/null +++ b/si-ps-conv-fastcorrs/pyproject.toml @@ -0,0 +1,79 @@ +[build-system] +requires = ["setuptools>=44"] +build-backend = "setuptools.build_meta" + +[project] +name = "si_ps_conv_fastcorrs" +authors = [{ name = "lnls-sirius" } ] +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 = "Conv IOC for Fast Corrector Power Supplies." +readme = "README.md" +dynamic = ["version", "dependencies"] +requires-python = ">=3.6" +classifiers = [ + "Intended Audience :: Science/Research", + "Programming Language :: Python", + "Topic :: Scientific/Engineering", +] +keywords = ["SIRIUS", "python", "EPICS"] + +license = "GPL-3.0" +license-files= [ "LICENSE", ] + +[project.urls] +Homepage = "https://github.com/lnls-sirius/machine-applications" +Download = "https://github.com/lnls-sirius/machine-applications" +Repository = "https://github.com/lnls-sirius/machine-applications.git" +Issues = "https://github.com/lnls-sirius/machine-applications/issues" + +# --- Setuptools specific configurations --- +[tool.setuptools] +include-package-data = true +# NOTE: This is not the standard way of defining scripts. +# Once we abandon phython3.6 and the setup.py file, we should +# consider using the table [projec.scripts], defining valid entrypoints. +script-files = [ + "scripts/sirius-ioc-si-ps-conv-fastcorrs.py", +] + +[tool.setuptools.dynamic] +version = { file = "VERSION" } +dependencies = { file = "requirements.txt" } + +[tool.setuptools.package-data] +si_ps_conv_fastcorrs = [ "VERSION",] + +# --- linter e formatter --- +[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