update flake and setup scheme

This commit is contained in:
Denis Lehmann 2021-07-15 09:43:43 +02:00
parent 25ef32dbbb
commit 94b8d29d43
3 changed files with 14 additions and 14 deletions

View File

@ -1,7 +1,7 @@
{ {
description = "A colorful wallpaper generator"; description = "A colorful wallpaper generator";
nixConfig.bash-prompt = "\[\\e[1m\\e[34mhuepaper-develop\\e[0m\]$ "; nixConfig.bash-prompt = "\[\\e[1m\\e[34mhuepaper-dev\\e[0m:\\w\]$ ";
inputs.flake-utils.url = "github:numtide/flake-utils"; inputs.flake-utils.url = "github:numtide/flake-utils";
@ -15,31 +15,26 @@
{ {
# Package # Package
packages.huepaper = packages.huepaper =
pkgs.python3Packages.buildPythonPackage rec { pkgs.python3Packages.buildPythonPackage rec {
name = "huepaper"; name = "huepaper";
src = self; src = self;
nativeBuildInputs = with pkgs; [
wrapGAppsHook
];
propagatedBuildInputs = with pkgs; [ propagatedBuildInputs = with pkgs; [
python3Packages.colour python3Packages.colour
python3Packages.pillow python3Packages.pillow
]; ];
}; };
defaultPackage = self.packages.${system}.huepaper; defaultPackage = self.packages.${system}.huepaper;
# App
apps.huepaper = {
type = "app";
program = "${self.packages.${system}.huepaper}/bin/huepaper";
};
defaultApp = self.apps.${system}.huepaper;
# Development shell # Development shell
devShell = pkgs.mkShell { devShell = pkgs.mkShell {
buildInputs = with pkgs; [ buildInputs = with pkgs; [
python3 python3
python3Packages.colour python3Packages.colour

View File

@ -10,7 +10,6 @@ from huepaper import (
save_image, save_image,
) )
import argparse import argparse
import os.path
def print_greeter(): def print_greeter():

View File

@ -1,4 +1,10 @@
from setuptools import setup from setuptools import setup
import os
import shutil
if not os.path.exists("bin"):
os.makedirs("bin")
shutil.copyfile("huepaper.py", "bin/huepaper")
setup( setup(
name="huepaper", name="huepaper",