2022-07-14 12:49:19 +00:00
|
|
|
{ mkDerivation, lib, fetchFromGitHub, qmake, qttools, qtx11extras, stdenv }:
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
mkDerivation rec {
|
|
|
|
pname = "notepad-next";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "0.6.4";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "dail8859";
|
|
|
|
repo = "NotepadNext";
|
|
|
|
rev = "v${version}";
|
2023-11-16 04:20:00 +00:00
|
|
|
sha256 = "sha256-m8+kM9uz3gJ3kvpgZdoonSvYlh/f1WiGZlB8JKMTXh4=";
|
2022-06-16 17:23:12 +00:00
|
|
|
# External dependencies - https://github.com/dail8859/NotepadNext/issues/135
|
|
|
|
fetchSubmodules = true;
|
|
|
|
};
|
|
|
|
|
2022-07-14 12:49:19 +00:00
|
|
|
nativeBuildInputs = [ qmake qttools ];
|
|
|
|
buildInputs = [ qtx11extras ];
|
|
|
|
|
|
|
|
qmakeFlags = [
|
|
|
|
"PREFIX=${placeholder "out"}"
|
|
|
|
"src/NotepadNext.pro"
|
|
|
|
];
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
postPatch = ''
|
2022-07-14 12:49:19 +00:00
|
|
|
substituteInPlace src/i18n.pri \
|
|
|
|
--replace 'EXTRA_TRANSLATIONS = \' "" \
|
|
|
|
--replace '$$[QT_INSTALL_TRANSLATIONS]/qt_zh_CN.qm' ""
|
2022-06-16 17:23:12 +00:00
|
|
|
'';
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
postInstall = lib.optionalString stdenv.isDarwin ''
|
|
|
|
mv $out/bin $out/Applications
|
|
|
|
rm -fr $out/share
|
|
|
|
'';
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/dail8859/NotepadNext";
|
2023-07-15 17:15:38 +00:00
|
|
|
description = "A cross-platform, reimplementation of Notepad++";
|
2022-06-16 17:23:12 +00:00
|
|
|
license = licenses.gpl3Plus;
|
2023-07-15 17:15:38 +00:00
|
|
|
platforms = platforms.unix;
|
2022-06-16 17:23:12 +00:00
|
|
|
maintainers = [ maintainers.sebtm ];
|
|
|
|
broken = stdenv.isAarch64;
|
|
|
|
};
|
|
|
|
}
|