mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
Merge pull request #120179 from fortuneteller2k/cleanup-polybar
polybar: use lib.optional
This commit is contained in:
commit
9fa4d44614
1 changed files with 12 additions and 16 deletions
|
@ -57,9 +57,8 @@ stdenv.mkDerivation rec {
|
||||||
pkg-config
|
pkg-config
|
||||||
python3Packages.sphinx
|
python3Packages.sphinx
|
||||||
removeReferencesTo
|
removeReferencesTo
|
||||||
|
]
|
||||||
(if i3Support || i3GapsSupport then makeWrapper else null)
|
++ lib.optional (i3Support || i3GapsSupport) makeWrapper;
|
||||||
];
|
|
||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
cairo
|
cairo
|
||||||
|
@ -75,19 +74,16 @@ stdenv.mkDerivation rec {
|
||||||
xcbutilrenderutil
|
xcbutilrenderutil
|
||||||
xcbutilwm
|
xcbutilwm
|
||||||
xcbutilxrm
|
xcbutilxrm
|
||||||
|
]
|
||||||
(if alsaSupport then alsaLib else null)
|
++ lib.optional alsaSupport alsaLib
|
||||||
(if githubSupport then curl else null)
|
++ lib.optional githubSupport curl
|
||||||
(if mpdSupport then libmpdclient else null)
|
++ lib.optional mpdSupport libmpdclient
|
||||||
(if pulseSupport then libpulseaudio else null)
|
++ lib.optional pulseSupport libpulseaudio
|
||||||
|
++ lib.optional iwSupport wirelesstools
|
||||||
(if iwSupport then wirelesstools else null)
|
++ lib.optional nlSupport libnl
|
||||||
(if nlSupport then libnl else null)
|
++ lib.optional (i3Support || i3GapsSupport) jsoncpp
|
||||||
|
++ lib.optional i3Support i3
|
||||||
(if i3Support || i3GapsSupport then jsoncpp else null)
|
++ lib.optional i3GapsSupport i3-gaps;
|
||||||
(if i3Support then i3 else null)
|
|
||||||
(if i3GapsSupport then i3-gaps else null)
|
|
||||||
];
|
|
||||||
|
|
||||||
postInstall = if i3Support
|
postInstall = if i3Support
|
||||||
then ''wrapProgram $out/bin/polybar \
|
then ''wrapProgram $out/bin/polybar \
|
||||||
|
|
Loading…
Reference in a new issue