mcdreforged: move to python-modules

This commit is contained in:
Moraxyc 2024-12-15 21:27:47 +08:00
parent 1140c2d192
commit 9971588613
No known key found for this signature in database
3 changed files with 67 additions and 51 deletions

View File

@ -1,51 +1 @@
{
lib,
fetchFromGitHub,
python3,
testers,
mcdreforged,
}:
python3.pkgs.buildPythonApplication rec {
pname = "mcdreforged";
version = "2.14.0";
pyproject = true;
src = fetchFromGitHub {
owner = "MCDReforged";
repo = "MCDReforged";
tag = "v${version}";
hash = "sha256-4podJ3InBnNc+t4BpCQrg2QbJ9ZJr5fmroXyzo7JrZw=";
};
build-system = [ python3.pkgs.setuptools ];
dependencies = with python3.pkgs; [
colorama
colorlog
packaging
parse
prompt-toolkit
psutil
requests
resolvelib
ruamel-yaml
typing-extensions
pathspec
];
nativeCheckInputs = [ python3.pkgs.pytestCheckHook ];
passthru.tests = {
version = testers.testVersion { package = mcdreforged; };
};
meta = {
description = "Rewritten version of MCDaemon, a python tool to control your Minecraft server";
homepage = "https://mcdreforged.com";
changelog = "https://github.com/MCDReforged/MCDReforged/releases/tag/v${version}";
license = lib.licenses.lgpl3Only;
maintainers = with lib.maintainers; [ moraxyc ];
mainProgram = "mcdreforged";
};
}
{ python3Packages }: with python3Packages; toPythonApplication mcdreforged

View File

@ -0,0 +1,64 @@
{
lib,
fetchFromGitHub,
buildPythonPackage,
setuptools,
colorama,
colorlog,
packaging,
parse,
prompt-toolkit,
psutil,
requests,
resolvelib,
ruamel-yaml,
typing-extensions,
pathspec,
pytestCheckHook,
testers,
mcdreforged,
}:
buildPythonPackage rec {
pname = "mcdreforged";
version = "2.14.0";
pyproject = true;
src = fetchFromGitHub {
owner = "MCDReforged";
repo = "MCDReforged";
tag = "v${version}";
hash = "sha256-4podJ3InBnNc+t4BpCQrg2QbJ9ZJr5fmroXyzo7JrZw=";
};
build-system = [ setuptools ];
dependencies = [
colorama
colorlog
packaging
parse
prompt-toolkit
psutil
requests
resolvelib
ruamel-yaml
typing-extensions
pathspec
];
nativeCheckInputs = [ pytestCheckHook ];
passthru.tests = {
version = testers.testVersion { package = mcdreforged; };
};
meta = {
description = "Rewritten version of MCDaemon, a python tool to control your Minecraft server";
homepage = "https://mcdreforged.com";
changelog = "https://github.com/MCDReforged/MCDReforged/releases/tag/v${version}";
license = lib.licenses.lgpl3Only;
maintainers = with lib.maintainers; [ moraxyc ];
mainProgram = "mcdreforged";
};
}

View File

@ -7994,6 +7994,8 @@ self: super: with self; {
mccabe = callPackage ../development/python-modules/mccabe { };
mcdreforged = callPackage ../development/python-modules/mcdreforged { };
mcstatus = callPackage ../development/python-modules/mcstatus { };
mcuuid = callPackage ../development/python-modules/mcuuid { };