summaryrefslogtreecommitdiff
path: root/derivations
diff options
context:
space:
mode:
Diffstat (limited to 'derivations')
-rw-r--r--derivations/crazydiskinfo/default.nix38
-rw-r--r--derivations/lowbat/default.nix32
-rw-r--r--derivations/pavolctld/default.nix28
-rw-r--r--derivations/st/default.nix43
4 files changed, 79 insertions, 62 deletions
diff --git a/derivations/crazydiskinfo/default.nix b/derivations/crazydiskinfo/default.nix
new file mode 100644
index 0000000..69d9fa1
--- /dev/null
+++ b/derivations/crazydiskinfo/default.nix
@@ -0,0 +1,38 @@
+{ lib
+, cmake
+, fetchFromGitHub
+, fetchpatch
+, libatasmart
+, ncurses5
+, stdenv
+}:
+
+stdenv.mkDerivation rec {
+ pname = "crazydiskinfo";
+ version = "1.1.0";
+
+ src = fetchFromGitHub {
+ owner = "otakuto";
+ repo = pname;
+ rev = "refs/tags/${version}";
+ sha256 = "sha256-+6ShoaggQ256sLSJDj4d16OipUYX/4JjEwLL5hswjiQ=";
+ };
+
+ patches = [
+ # Fix build warnings, original maintainer is MIA
+ (fetchpatch {
+ url = "https://patch-diff.githubusercontent.com/raw/otakuto/crazydiskinfo/pull/33.diff";
+ sha256 = "sha256-z9aOQFsivu6sYgsZBOlnTvqnoR2ro/jyuO/WOimLSXk=";
+ })
+ ];
+
+ buildInputs = [ cmake libatasmart ncurses5 ];
+
+ cmakeFlags = [ "-DCMAKE_INSTALL_PREFIX=$out" ];
+
+ meta = with lib; {
+ description = "CrazyDiskInfo is an interactive TUI S.M.A.R.T viewer for Unix systems";
+ license = licenses.mit;
+ maintainers = [ maintainers.tjkeller ];
+ };
+}
diff --git a/derivations/lowbat/default.nix b/derivations/lowbat/default.nix
index 02ff111..64ec205 100644
--- a/derivations/lowbat/default.nix
+++ b/derivations/lowbat/default.nix
@@ -1,28 +1,26 @@
-{ pkgs ? import <nixpkgs> {} }:
+{ lib
+, fetchzip
+, glib
+, libnotify
+, pkg-config
+, stdenv
+}:
-pkgs.stdenv.mkDerivation rec {
+stdenv.mkDerivation rec {
pname = "lowbat";
- version = "1.2.1";
+ version = "1.2.2";
- src = pkgs.fetchzip {
+ src = fetchzip {
url = "https://git.tjkeller.xyz/${pname}/snapshot/${pname}-${version}.tar.xz";
- sha256 = "sha256-xsUHdmicHX/fQQgojVjWfzI82e4NezkmlACOpdPxLE0=";
+ sha256 = "sha256-utdcY9qoDcrBWnGC8m/LUsnoxQ0ilssPDF44A6D/C+8=";
};
- nativeBuildInputs = [ pkgs.pkg-config ];
- buildInputs = [ pkgs.libnotify pkgs.glib ];
+ nativeBuildInputs = [ pkg-config ];
+ buildInputs = [ libnotify glib ];
- buildPhase = ''
- make
- '';
+ installFlags = [ "PREFIX=$(out)" ];
- installPhase = ''
- mkdir -p $out/bin $out/share/man/man1
- cp lowbat $out/bin/
- cp lowbat.1 $out/share/man/man1/
- '';
-
- meta = with pkgs.lib; {
+ meta = with lib; {
description = "A minimal battery level monitor daemon, written in C";
license = licenses.mit;
maintainers = [ maintainers.tjkeller ];
diff --git a/derivations/pavolctld/default.nix b/derivations/pavolctld/default.nix
index c78e3fe..d092ed5 100644
--- a/derivations/pavolctld/default.nix
+++ b/derivations/pavolctld/default.nix
@@ -1,27 +1,23 @@
-{ pkgs ? import <nixpkgs> {} }:
+{ lib
+, fetchzip
+, libpulseaudio
+, stdenv
+}:
-pkgs.stdenv.mkDerivation rec {
+stdenv.mkDerivation rec {
pname = "pavolctld";
- version = "1.0.0";
+ version = "1.0.1";
- src = pkgs.fetchzip {
+ src = fetchzip {
url = "https://git.tjkeller.xyz/${pname}/snapshot/${pname}-${version}.tar.xz";
- sha256 = "sha256-eJ5njP2wu2kxsNgDdULOaATJJarLh+LkM5M9+kujRt4=";
+ sha256 = "sha256-nmN8bQKQNGpCGvHQnZK9YQgB80SxRSds0V9Y7h/Guh8=";
};
- buildInputs = [ pkgs.libpulseaudio ];
+ buildInputs = [ libpulseaudio ];
- buildPhase = ''
- make
- '';
+ installFlags = [ "PREFIX=$(out)" ];
- installPhase = ''
- mkdir -p $out/bin $out/share/man/man1
- cp pavolctld $out/bin/
- cp pavolctld.1 $out/share/man/man1/
- '';
-
- meta = with pkgs.lib; {
+ meta = with lib; {
description = "A minimal PulseAudio volume control/monitoring daemon";
license = licenses.mit;
maintainers = [ maintainers.tjkeller ];
diff --git a/derivations/st/default.nix b/derivations/st/default.nix
index eb7c6bc..4c7f3a6 100644
--- a/derivations/st/default.nix
+++ b/derivations/st/default.nix
@@ -1,14 +1,13 @@
-{
- lib,
- stdenv,
- fetchzip,
- fontconfig,
- libX11,
- libXcursor,
- libXext,
- libXft,
- ncurses,
- pkg-config,
+{ lib
+, fetchzip
+, fontconfig
+, libX11
+, libXcursor
+, libXext
+, libXft
+, ncurses
+, pkg-config
+, stdenv
}:
stdenv.mkDerivation rec {
@@ -20,25 +19,11 @@ stdenv.mkDerivation rec {
sha256 = "sha256-p1u7TEeLeC5Kjvi8na4YhyQQ0qdPaUWZL6hq9O4HaKA=";
};
- nativeBuildInputs = [
- pkg-config
- ];
- buildInputs = [
- fontconfig
- libX11
- libXcursor
- libXext
- libXft
- ncurses
- ];
+ nativeBuildInputs = [ pkg-config ];
+ buildInputs = [ fontconfig libX11 libXcursor libXext libXft ncurses ];
- installPhase = ''
- runHook preInstall
-
- TERMINFO=$out/share/terminfo make install PREFIX=$out
-
- runHook postInstall
- '';
+ makeFlags = [ "CFLAGS=-Ofast" ];
+ installFlags = [ "PREFIX=$(out)" "TERMINFO=$(out)/share/terminfo" ];
meta = with lib; {
homepage = "https://git.tjkeller.xyz/st";