mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-25 15:13:46 +00:00
4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
54 lines
1.2 KiB
Nix
54 lines
1.2 KiB
Nix
{ lib, stdenv
|
|
, fetchFromGitHub
|
|
, autoreconfHook
|
|
, pkg-config
|
|
, expat
|
|
, gettext
|
|
, gtk
|
|
, libconfuse
|
|
, pcre2
|
|
, vte
|
|
, makeWrapper
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "tilda";
|
|
version = "1.5.4";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "lanoxx";
|
|
repo = "tilda";
|
|
rev = "${pname}-${version}";
|
|
sha256 = "sha256-uDx28jmjNUyzJbgTJiHbjI9U5mYb9bnfl/9AjbxNUWA=";
|
|
};
|
|
|
|
nativeBuildInputs = [ autoreconfHook makeWrapper pkg-config ];
|
|
buildInputs = [
|
|
gettext
|
|
gtk
|
|
libconfuse
|
|
pcre2
|
|
vte
|
|
];
|
|
|
|
LD_LIBRARY_PATH = "${expat.out}/lib"; # ugly hack for xgettext to work during build
|
|
|
|
# The config locking scheme relies on the binary being called "tilda",
|
|
# (`pgrep -C tilda`), so a simple `wrapProgram` won't suffice:
|
|
postInstall = ''
|
|
mkdir $out/bin/wrapped
|
|
mv "$out/bin/tilda" "$out/bin/wrapped/tilda"
|
|
makeWrapper "$out/bin/wrapped/tilda" "$out/bin/tilda" \
|
|
--prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "A Gtk based drop down terminal for Linux and Unix";
|
|
homepage = "https://github.com/lanoxx/tilda/";
|
|
license = licenses.gpl3Plus;
|
|
maintainers = [ maintainers.AndersonTorres ];
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|
|
|