From 9642abde75968308074c4c8f28766f198a1bf322 Mon Sep 17 00:00:00 2001 From: awwpotato Date: Sat, 19 Apr 2025 19:46:12 -0700 Subject: [PATCH 1/2] textadept: modernize --- .../editors/textadept/default.nix | 25 ++++++++++--------- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/pkgs/applications/editors/textadept/default.nix b/pkgs/applications/editors/textadept/default.nix index da5ffb192a3f..44632c5797dd 100644 --- a/pkgs/applications/editors/textadept/default.nix +++ b/pkgs/applications/editors/textadept/default.nix @@ -5,12 +5,11 @@ fetchurl, cmake, withQt ? true, - qtbase, - wrapQtAppsHook, + libsForQt5, withCurses ? false, ncurses, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { version = "12.4"; pname = "textadept"; @@ -18,13 +17,13 @@ stdenv.mkDerivation rec { name = "textadept11"; owner = "orbitalquark"; repo = "textadept"; - rev = "textadept_${version}"; - sha256 = "sha256-nPgpQeBq5Stv2o0Ke4W2Ltnx6qLe5TIC5a8HSYVkmfI="; + tag = "textadept_${finalAttrs.version}"; + hash = "sha256-nPgpQeBq5Stv2o0Ke4W2Ltnx6qLe5TIC5a8HSYVkmfI="; }; - nativeBuildInputs = [ cmake ] ++ lib.optionals withQt [ wrapQtAppsHook ]; + nativeBuildInputs = [ cmake ] ++ lib.optionals withQt [ libsForQt5.wrapQtAppsHook ]; - buildInputs = lib.optionals withQt [ qtbase ] ++ lib.optionals withCurses ncurses; + buildInputs = lib.optionals withQt [ libsForQt5.qtbase ] ++ lib.optionals withCurses ncurses; cmakeFlags = lib.optional withQt [ "-DQT=ON" ] @@ -44,16 +43,18 @@ stdenv.mkDerivation rec { ) (import ./deps.nix) ); - meta = with lib; { + meta = { description = "Extensible text editor based on Scintilla with Lua scripting"; homepage = "http://foicica.com/textadept"; - license = licenses.mit; - maintainers = with maintainers; [ + downloadPage = "https://github.com/orbitalquark/textadept"; + changelog = "https://github.com/orbitalquark/textadept/releases/tag/textadept_${finalAttrs.version}"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ raskin mirrexagon arcuru ]; - platforms = platforms.linux; + platforms = lib.platforms.linux; mainProgram = "textadept"; }; -} +}) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 548a6291147d..a26aeb132c88 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5307,7 +5307,7 @@ with pkgs; texmaker = qt6Packages.callPackage ../applications/editors/texmaker { }; - textadept = libsForQt5.callPackage ../applications/editors/textadept { }; + textadept = callPackage ../applications/editors/textadept { }; texworks = qt6Packages.callPackage ../applications/editors/texworks { }; From a291b0d572578731460b8fad0d84f3bee39463da Mon Sep 17 00:00:00 2001 From: awwpotato Date: Sat, 19 Apr 2025 19:47:16 -0700 Subject: [PATCH 2/2] textadept: move to by-name --- pkgs/{applications/editors => by-name/te}/textadept/deps.nix | 0 .../textadept/default.nix => by-name/te/textadept/package.nix} | 0 pkgs/top-level/all-packages.nix | 2 -- 3 files changed, 2 deletions(-) rename pkgs/{applications/editors => by-name/te}/textadept/deps.nix (100%) rename pkgs/{applications/editors/textadept/default.nix => by-name/te/textadept/package.nix} (100%) diff --git a/pkgs/applications/editors/textadept/deps.nix b/pkgs/by-name/te/textadept/deps.nix similarity index 100% rename from pkgs/applications/editors/textadept/deps.nix rename to pkgs/by-name/te/textadept/deps.nix diff --git a/pkgs/applications/editors/textadept/default.nix b/pkgs/by-name/te/textadept/package.nix similarity index 100% rename from pkgs/applications/editors/textadept/default.nix rename to pkgs/by-name/te/textadept/package.nix diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a26aeb132c88..bd36fb61ce1a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5307,8 +5307,6 @@ with pkgs; texmaker = qt6Packages.callPackage ../applications/editors/texmaker { }; - textadept = callPackage ../applications/editors/textadept { }; - texworks = qt6Packages.callPackage ../applications/editors/texworks { }; theLoungePlugins =