2022-05-18 14:49:53 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, makeWrapper
|
|
|
|
, git
|
|
|
|
, bc
|
|
|
|
, bspwm
|
|
|
|
}:
|
2021-06-04 09:07:49 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "bsp-layout";
|
2022-07-14 12:49:19 +00:00
|
|
|
version = "unstable-2022-06-19";
|
2021-06-04 09:07:49 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "phenax";
|
|
|
|
repo = pname;
|
2022-07-14 12:49:19 +00:00
|
|
|
rev = "181d38443778e81df2d4bc3639063c3ae608f9c7";
|
|
|
|
sha256 = "sha256-4NKI+OnOTYGaJnaPvSoXGJdSSzMo9AjYRLOomp9onoo=";
|
2021-06-04 09:07:49 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ makeWrapper git bc ];
|
|
|
|
buildInputs = [ bspwm ];
|
|
|
|
|
|
|
|
makeFlags = [ "PREFIX=$(out)" ];
|
|
|
|
|
|
|
|
postInstall = ''
|
2022-05-18 14:49:53 +00:00
|
|
|
substituteInPlace $out/lib/bsp-layout/layout.sh --replace 'bc ' '${bc}/bin/bc '
|
|
|
|
for layout in tall rtall wide rwide
|
|
|
|
do
|
|
|
|
substituteInPlace "$out/lib/bsp-layout/layouts/$layout.sh" --replace 'bc ' '${bc}/bin/bc '
|
|
|
|
done
|
2021-06-04 09:07:49 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Manage layouts in bspwm";
|
2022-05-18 14:49:53 +00:00
|
|
|
longDescription = ''
|
|
|
|
bsp-layout is a dynamic layout manager for bspwm, written in bash.
|
|
|
|
It provides layout options to fit most workflows.
|
|
|
|
'';
|
2021-06-04 09:07:49 +00:00
|
|
|
homepage = "https://github.com/phenax/bsp-layout";
|
|
|
|
license = licenses.mit;
|
2022-07-14 12:49:19 +00:00
|
|
|
maintainers = with maintainers; [ totoroot ];
|
2021-06-04 09:07:49 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|