From 287d63b41af7d67986b41441cf9d64c5824f4089 Mon Sep 17 00:00:00 2001 From: notohh Date: Sat, 1 Jun 2024 14:46:29 -0400 Subject: [PATCH] pkgs: add forex && passgen --- pkgs/forex/default.nix | 30 ++++++++++++++++++++++++++++++ pkgs/passgen/default.nix | 26 ++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 pkgs/forex/default.nix create mode 100644 pkgs/passgen/default.nix diff --git a/pkgs/forex/default.nix b/pkgs/forex/default.nix new file mode 100644 index 0000000..415cf3b --- /dev/null +++ b/pkgs/forex/default.nix @@ -0,0 +1,30 @@ +{ + pkgs, + lib, + rustPlatform, + fetchFromGitea, + ... +}: +rustPlatform.buildRustPackage { + name = "forex"; + src = fetchFromGitea { + domain = "git.flake.sh"; + owner = "notohh"; + repo = "forex"; + rev = "de4b32b0d5bf0631404dd11c5878058bc7fd4a56"; + sha256 = "sha256-d/iyg/tFF3N0I6LCSFU4U1vBzpz60s2FnT0GB4AuihE="; + }; + + nativeBuildInputs = [pkgs.pkg-config]; + buildInputs = [pkgs.openssl]; + + cargoSha256 = "sha256-COWFG766DVWXbGm8raVSH1nBpsS5HdTat5BHzv7QR4o="; + + meta = with lib; { + description = "a CLI currency converter, written in rust, for practice"; + mainProgram = "forex"; + homepage = "https://git.flake.sh/notohh/forex"; + license = licenses.mit; + maintainers = with maintainers; [notohh]; + }; +} diff --git a/pkgs/passgen/default.nix b/pkgs/passgen/default.nix new file mode 100644 index 0000000..00415c4 --- /dev/null +++ b/pkgs/passgen/default.nix @@ -0,0 +1,26 @@ +{ + rustPlatform, + fetchFromGitea, + lib, + ... +}: +rustPlatform.buildRustPackage { + name = "passgen"; + src = fetchFromGitea { + domain = "git.flake.sh"; + owner = "notohh"; + repo = "passgen"; + rev = "fa2181af70b5efa0376a5f6ffa937073b2201339"; + sha256 = "sha256-E77mzceKBaXOjW/C/aHfUltt1Wb7RAzvJzhlgmbxkoE="; + }; + + cargoSha256 = "sha256-A8W7Qz+8cy6sPjLBC5a4Brz+cCyGPeNM1f7oZ6pmfe0="; + + meta = with lib; { + description = "password generator for rust practice"; + mainProgram = "passgen"; + homepage = "https://git.flake.sh/notohh/passgen"; + license = licenses.mit; + maintainers = with maintainers; [notohh]; + }; +}