Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

treewide: migrate packages to by-name hierarchy #254417

Merged
merged 20 commits into from
Oct 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,29 +1,35 @@
{ lib, stdenv
{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, pkg-config
, appstream-glib
, autoreconfHook
, dbus
, pango
, pcre2
, pkg-config
, tmux
, vte
, wrapGAppsHook
, nixosTests
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "germinal";
version = "26";

src = fetchFromGitHub {
owner = "Keruspe";
repo = "Germinal";
rev = "v${version}";
sha256 = "sha256-HUi+skF4bJj5CY2cNTOC4tl7jhvpXYKqBx2rqKzjlo0=";
rev = "v${finalAttrs.version}";
hash = "sha256-HUi+skF4bJj5CY2cNTOC4tl7jhvpXYKqBx2rqKzjlo0=";
};

nativeBuildInputs = [ autoreconfHook pkg-config wrapGAppsHook ];
nativeBuildInputs = [
autoreconfHook
pkg-config
wrapGAppsHook
];

buildInputs = [
appstream-glib
dbus
Expand All @@ -48,11 +54,12 @@ stdenv.mkDerivation rec {

passthru.tests.test = nixosTests.terminal-emulators.germinal;

meta = with lib; {
meta = {
description = "A minimal terminal emulator";
homepage = "https://github.com/Keruspe/Germinal";
license = with licenses; gpl3Plus;
platforms = with platforms; unix;
maintainers = with maintainers; [ AndersonTorres ];
license = lib.licenses.gpl3Plus;
mainProgram = "germinal";
maintainers = with lib.maintainers; [ AndersonTorres ];
platforms = lib.platforms.unix;
};
}
})
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,20 @@
, fetchurl
, fetchpatch
, autoreconfHook
, callPackage
, guile
, guile-commonmark
, guile-reader
, makeWrapper
, pkg-config
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "haunt";
version = "0.2.6";

src = fetchurl {
url = "https://files.dthompson.us/${pname}/${pname}-${version}.tar.gz";
url = "https://files.dthompson.us/haunt/haunt-${finalAttrs.version}.tar.gz";
hash = "sha256-vPKLQ9hDJdimEAXwIBGgRRlefM8/77xFQoI+0J/lkNs=";
};

Expand All @@ -40,6 +41,7 @@ stdenv.mkDerivation rec {
makeWrapper
pkg-config
];

buildInputs = [
guile
guile-commonmark
Expand All @@ -55,14 +57,13 @@ stdenv.mkDerivation rec {
--prefix GUILE_LOAD_COMPILED_PATH : "$out/${guile.siteCcacheDir}:$GUILE_LOAD_COMPILED_PATH"
'';

doInstallCheck = true;
installCheckPhase = ''
runHook preInstallCheck
$out/bin/haunt --version
runHook postInstallCheck
'';
passthru = {
tests = {
expectVersion = callPackage ./tests/001-test-version.nix { };
};
};

meta = with lib; {
meta = {
homepage = "https://dthompson.us/projects/haunt.html";
description = "Guile-based static site generator";
longDescription = ''
Expand All @@ -81,8 +82,8 @@ stdenv.mkDerivation rec {
feeds, authors should feel empowered to tweak, replace, or create builders
to do things that aren't provided out-of-the-box.
'';
license = licenses.gpl3Plus;
maintainers = with maintainers; [ AndersonTorres AluisioASG ];
platforms = guile.meta.platforms;
license = lib.licenses.gpl3Plus;
maintainers = with lib.maintainers; [ AndersonTorres AluisioASG ];
inherit (guile.meta) platforms;
};
}
})
21 changes: 21 additions & 0 deletions pkgs/by-name/ha/haunt/tests/001-test-version.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{ lib
, stdenv
, haunt
}:

stdenv.mkDerivation {
pname = "haunt-test-version";
inherit (haunt) version;

nativeBuildInputs = [ haunt ];

dontInstall = true;

buildCommand = ''
haunt --version

touch $out
'';

meta.timeout = 10;
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@
, fetchFromGitHub
, libxkbcommon
, pkg-config
, wayland
, wayland-protocols
, wayland-scanner
, wayland
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "havoc";
version = "0.5.0";

src = fetchFromGitHub {
owner = "ii8";
repo = pname;
rev = version;
repo = "havoc";
rev = finalAttrs.version;
hash = "sha256-jvGm2gFdMS61otETF7gOEpYn6IuLfqI95IpEVfIv+C4=";
};

Expand All @@ -38,19 +38,19 @@ stdenv.mkDerivation rec {
installFlags = [ "PREFIX=$$out" ];

postInstall = ''
install -D -m 644 havoc.cfg -t $out/etc/${pname}/
install -D -m 644 README.md -t $out/share/doc/${pname}-${version}/
install -Dm 644 havoc.cfg -t $out/etc/havoc/
install -Dm 644 README.md -t $out/share/doc/havoc-${finalAttrs.version}/
'';

enableParallelBuilding = true;

meta = with lib; {
meta = {
homepage = "https://github.com/ii8/havoc";
description = "A minimal terminal emulator for Wayland";
license = with licenses; [ mit publicDomain ];
platforms = with platforms; unix;
maintainers = with maintainers; [ AndersonTorres ];
# fatal error: 'sys/epoll.h' file not found
broken = stdenv.isDarwin;
license = with lib.licenses; [ mit publicDomain ];
mainProgram = "havoc";
maintainers = with lib.maintainers; [ AndersonTorres ];
inherit (wayland.meta) platforms;
broken = stdenv.isDarwin; # fatal error: 'sys/epoll.h' file not found
};
}
})
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,13 @@ stdenv.mkDerivation (finalAttrs: {

src = fetchFromGitHub {
owner = "orhun";
repo = finalAttrs.pname;
repo = "kermit";
rev = finalAttrs.version;
hash = "sha256-XPHF33Nu+H8OcQFwsuUOhDBDWKm8sh5B36sfROeSWPg=";
};

outputs = [ "out" "man" ];

nativeBuildInputs = [
cmake
pkg-config
Expand All @@ -33,12 +35,13 @@ stdenv.mkDerivation (finalAttrs: {

passthru.tests.test = nixosTests.terminal-emulators.kermit;

meta = with lib; {
meta = {
homepage = "https://github.com/orhun/kermit";
description = "A VTE-based, simple and froggy terminal emulator";
changelog = "https://github.com/orhun/kermit/releases/tag/${finalAttrs.version}";
license = licenses.gpl3Only;
maintainers = with maintainers; [ AndersonTorres ];
platforms = with platforms; unix;
license = lib.licenses.gpl3Only;
mainProgram = "kermit";
maintainers = with lib.maintainers; [ AndersonTorres ];
platforms = lib.platforms.unix;
};
})
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
, autoreconfHook
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "robodoc";
version = "4.99.44";

src = fetchFromGitHub {
owner = "gumpu";
repo = "ROBODoc";
rev = "v${version}";
sha256 = "l3prSdaGhOvXmZfCPbsZJNocO7y20zJjLQpajRTJOqE=";
rev = "v${finalAttrs.version}";
hash = "sha256-l3prSdaGhOvXmZfCPbsZJNocO7y20zJjLQpajRTJOqE=";
};

postConfigure = lib.optionalString stdenv.isDarwin ''
Expand Down Expand Up @@ -48,6 +48,6 @@ stdenv.mkDerivation rec {
'';
license = with licenses; gpl3Plus;
maintainers = with maintainers; [ AndersonTorres ];
platforms = with platforms; all;
platforms = platforms.all;
};
}
})
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
, unzip
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "scimark";
version = "4c";

src = fetchurl {
url = "https://math.nist.gov/scimark2/${pname}${version}.zip";
url = "https://math.nist.gov/scimark2/scimark${finalAttrs.version}.zip";
hash = "sha256-kcg5vKYp0B7+bC/CmFMO/tMwxf9q6nvuFv0vRSy3MbE=";
};

Expand All @@ -20,17 +20,21 @@ stdenv.mkDerivation rec {
dontConfigure = true;

installPhase = ''
install -d $out/bin/
install scimark4 $out/bin/
runHook preInstall

install -Dm755 scimark4 -t $out/bin/

runHook postInstall
'';

meta = with lib; {
meta = {
homepage = "https://math.nist.gov/scimark2/index.html";
description = "Scientific and numerical computing benchmark (ANSI C version)";
license = licenses.publicDomain;
maintainers = with maintainers; [ AndersonTorres ];
downloadPage = "https://math.nist.gov/scimark2/download_c.html";
license = lib.licenses.publicDomain;
mainProgram = "scimark4";
platforms = platforms.all;
maintainers = with lib.maintainers; [ AndersonTorres ];
platforms = lib.platforms.all;
};
}
})
# TODO [ AndersonTorres ]: Java version
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
, darwin
}:

stdenv.mkDerivation {
stdenv.mkDerivation (finalAttrs: {
pname = "sound-of-sorting";
version = "unstable-2022-10-12";
version = "0.6.5-unstable-2022-10-12";

src = fetchFromGitHub {
owner = "bingmann";
Expand All @@ -26,13 +26,16 @@ stdenv.mkDerivation {
wxGTK32
SDL2
]
++ lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Cocoa ;
++ lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.Cocoa
];

meta = {
description = "Audibilization and Visualization of Sorting Algorithms";
homepage = "https://panthema.net/2013/sound-of-sorting/";
license = lib.licenses.gpl3Plus;
mainProgram = "sound-of-sorting";
maintainers = with lib.maintainers; [ AndersonTorres ];
platforms = lib.platforms.unix;
inherit (SDL2.meta) platforms;
};
}
})
Loading