fix(coloryou): update build system
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2025-02-28 22:31:17 -05:00
parent 2e15e10fd5
commit 24fc4b6ad2
5 changed files with 31 additions and 27 deletions

View file

@ -1,5 +1,3 @@
#!/usr/bin/env python
"""
The original script:
https://github.com/dharmx/vile/blob/7d486c128c7e553912673755f97b118aaab0193d/src/shell/playerctl.py#L2

View file

@ -1,20 +1,24 @@
{ python3Packages }:
{python3Packages, ...}: let
inherit (builtins.fromTOML (builtins.readFile ./pyproject.toml)) project;
in
python3Packages.buildPythonPackage {
pname = project.name;
inherit (project) version;
pyproject = true;
python3Packages.buildPythonPackage rec {
pname = "coloryou";
version = "0.0.1";
src = ./.;
src = ./.;
nativeBuildInputs = with python3Packages; [
setuptools
];
propagatedBuildInputs = with python3Packages; [ utils material-color-utilities ];
propagatedBuildInputs = with python3Packages; [material-color-utilities];
postInstall = ''
mv -v $out/bin/coloryou.py $out/bin/coloryou
'';
meta = {
description = ''
Get Material You colors from an image.
postInstall = ''
mv -v $out/bin/coloryou.py $out/bin/coloryou
'';
};
}
meta = {
inherit (project) description;
};
}

View file

@ -0,0 +1,12 @@
[build-system]
requires = ["setuptools"]
build-backend = "setuptools.build_meta"
[project]
name = "coloryou"
description="Get Material You colors from an image."
version = "0.1.0"
dependencies = [
"material_color_utilities_python",
]

View file

@ -1,7 +1,5 @@
from distutils.core import setup
setup(
name='coloryou',
version='0.0.1',
scripts=['coloryou.py',],
)

View file

@ -1,8 +0,0 @@
with import <nixpkgs> {};
with pkgs.python311Packages;
buildPythonPackage rec {
name = "coloryou";
src = ./.;
propagatedBuildInputs = [ material-color-utilities utils ];
}