forked from M-Labs/thermostat
pytec GUI: Set up packaging
Co-authored-by: Egor Savkin <es@m-labs.hk>
This commit is contained in:
parent
c5ad9a355e
commit
a9e7fbc394
29
flake.nix
29
flake.nix
@ -72,13 +72,40 @@
|
||||
numpy
|
||||
];
|
||||
};
|
||||
|
||||
thermostat_gui = pkgs.python3Packages.buildPythonPackage {
|
||||
pname = "thermostat_gui";
|
||||
version = "0.0.0";
|
||||
format = "pyproject";
|
||||
src = "${self}/pytec";
|
||||
|
||||
nativeBuildInputs = [ pkgs.qt6.wrapQtAppsHook ];
|
||||
propagatedBuildInputs =
|
||||
[ pkgs.qt6.qtbase ]
|
||||
++ (with pkgs.python3Packages; [
|
||||
pyqtgraph
|
||||
pyqt6
|
||||
qasync
|
||||
pglive
|
||||
]);
|
||||
|
||||
dontWrapQtApps = true;
|
||||
postFixup = ''
|
||||
wrapQtApp "$out/bin/tec_qt"
|
||||
'';
|
||||
};
|
||||
in
|
||||
{
|
||||
packages.x86_64-linux = {
|
||||
inherit thermostat;
|
||||
inherit thermostat thermostat_gui;
|
||||
default = thermostat;
|
||||
};
|
||||
|
||||
apps.x86_64-linux.thermostat_gui = {
|
||||
type = "app";
|
||||
program = "${self.packages.x86_64-linux.thermostat_gui}/bin/tec_qt";
|
||||
};
|
||||
|
||||
hydraJobs = {
|
||||
inherit thermostat;
|
||||
};
|
||||
|
4
pytec/MANIFEST.in
Normal file
4
pytec/MANIFEST.in
Normal file
@ -0,0 +1,4 @@
|
||||
graft examples
|
||||
include pytec/gui/resources/artiq.ico
|
||||
include pytec/gui/view/param_tree.json
|
||||
include pytec/gui/view/tec_qt.ui
|
18
pytec/pyproject.toml
Normal file
18
pytec/pyproject.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[build-system]
|
||||
requires = ["setuptools"]
|
||||
build-backend = "setuptools.build_meta"
|
||||
|
||||
[project]
|
||||
name = "pytec"
|
||||
version = "0.0"
|
||||
authors = [{name = "M-Labs"}]
|
||||
description = "Control TEC"
|
||||
urls.Repository = "https://git.m-labs.hk/M-Labs/thermostat"
|
||||
license = {text = "GPLv3"}
|
||||
|
||||
[project.gui-scripts]
|
||||
tec_qt = "tec_qt:main"
|
||||
|
||||
[tool.setuptools]
|
||||
packages.find = {}
|
||||
py-modules = ["autotune", "plot", "tec_qt"]
|
@ -9,4 +9,10 @@ setup(
|
||||
license="GPLv3",
|
||||
install_requires=["setuptools"],
|
||||
packages=find_packages(),
|
||||
entry_points={
|
||||
"gui_scripts": [
|
||||
"tec_qt = tec_qt:main",
|
||||
]
|
||||
},
|
||||
py_modules=['autotune', 'plot', 'tec_qt'],
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user