mirror of
https://github.com/donovanglover/nix-config.git
synced 2025-01-22 05:38:36 +01:00
waybar: Update to 0.9.18
Note that with the latest version of waybar with the experimental flag enabled and the latest version of hyprland, patching waybar *shouldn't* be necessary.
This commit is contained in:
parent
26c390dd69
commit
c946307c67
@ -1,10 +1,10 @@
|
|||||||
{ lib, hyprland, ... }:
|
{ lib, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
home-manager.sharedModules = [{
|
home-manager.sharedModules = [{
|
||||||
programs.waybar = {
|
programs.waybar = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = hyprland.packages."x86_64-linux".waybar-hyprland;
|
package = (pkgs.callPackage ./package {});
|
||||||
|
|
||||||
settings = {
|
settings = {
|
||||||
mainBar = {
|
mainBar = {
|
||||||
|
120
desktop/waybar/package/default.nix
Normal file
120
desktop/waybar/package/default.nix
Normal file
@ -0,0 +1,120 @@
|
|||||||
|
{ lib
|
||||||
|
, stdenv
|
||||||
|
, fetchFromGitHub
|
||||||
|
, meson
|
||||||
|
, pkg-config
|
||||||
|
, ninja
|
||||||
|
, wrapGAppsHook
|
||||||
|
, wayland
|
||||||
|
, wlroots
|
||||||
|
, gtkmm3
|
||||||
|
, libsigcxx
|
||||||
|
, jsoncpp
|
||||||
|
, scdoc
|
||||||
|
, spdlog
|
||||||
|
, gtk-layer-shell
|
||||||
|
, howard-hinnant-date
|
||||||
|
, libinotify-kqueue
|
||||||
|
, libxkbcommon
|
||||||
|
, evdevSupport ? true, libevdev
|
||||||
|
, inputSupport ? true, libinput
|
||||||
|
, jackSupport ? true, libjack2
|
||||||
|
, mpdSupport ? true, libmpdclient
|
||||||
|
, mprisSupport ? stdenv.isLinux, playerctl ? false
|
||||||
|
, nlSupport ? true, libnl
|
||||||
|
, pulseSupport ? true, libpulseaudio
|
||||||
|
, rfkillSupport ? true
|
||||||
|
, runTests ? true, catch2_3
|
||||||
|
, sndioSupport ? true, sndio
|
||||||
|
, swaySupport ? true, sway
|
||||||
|
, traySupport ? true, libdbusmenu-gtk3
|
||||||
|
, udevSupport ? true, udev
|
||||||
|
, upowerSupport ? true, upower
|
||||||
|
, wireplumberSupport ? true, wireplumber
|
||||||
|
, withMediaPlayer ? mprisSupport && false, glib, gobject-introspection, python3
|
||||||
|
}:
|
||||||
|
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "waybar";
|
||||||
|
version = "0.9.18";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "Alexays";
|
||||||
|
repo = "Waybar";
|
||||||
|
rev = version;
|
||||||
|
hash = "sha256-bnaYNa1jb7kZ1mtMzeOQqz4tmBG1w5YXlQWoop1Q0Yc=";
|
||||||
|
};
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
meson ninja pkg-config scdoc wrapGAppsHook
|
||||||
|
] ++ lib.optional withMediaPlayer gobject-introspection;
|
||||||
|
|
||||||
|
propagatedBuildInputs = lib.optionals withMediaPlayer [
|
||||||
|
glib
|
||||||
|
playerctl
|
||||||
|
python3.pkgs.pygobject3
|
||||||
|
];
|
||||||
|
|
||||||
|
strictDeps = false;
|
||||||
|
|
||||||
|
buildInputs = with lib;
|
||||||
|
[ wayland wlroots gtkmm3 libsigcxx jsoncpp spdlog gtk-layer-shell howard-hinnant-date libxkbcommon ]
|
||||||
|
++ optional (!stdenv.isLinux) libinotify-kqueue
|
||||||
|
++ optional evdevSupport libevdev
|
||||||
|
++ optional inputSupport libinput
|
||||||
|
++ optional jackSupport libjack2
|
||||||
|
++ optional mpdSupport libmpdclient
|
||||||
|
++ optional mprisSupport playerctl
|
||||||
|
++ optional nlSupport libnl
|
||||||
|
++ optional pulseSupport libpulseaudio
|
||||||
|
++ optional sndioSupport sndio
|
||||||
|
++ optional swaySupport sway
|
||||||
|
++ optional traySupport libdbusmenu-gtk3
|
||||||
|
++ optional udevSupport udev
|
||||||
|
++ optional upowerSupport upower
|
||||||
|
++ optional wireplumberSupport wireplumber;
|
||||||
|
|
||||||
|
nativeCheckInputs = [ catch2_3 ];
|
||||||
|
doCheck = runTests;
|
||||||
|
|
||||||
|
mesonFlags = (lib.mapAttrsToList
|
||||||
|
(option: enable: "-D${option}=${if enable then "enabled" else "disabled"}")
|
||||||
|
{
|
||||||
|
dbusmenu-gtk = traySupport;
|
||||||
|
jack = jackSupport;
|
||||||
|
libinput = inputSupport;
|
||||||
|
libnl = nlSupport;
|
||||||
|
libudev = udevSupport;
|
||||||
|
mpd = mpdSupport;
|
||||||
|
mpris = mprisSupport;
|
||||||
|
pulseaudio = pulseSupport;
|
||||||
|
rfkill = rfkillSupport;
|
||||||
|
sndio = sndioSupport;
|
||||||
|
tests = runTests;
|
||||||
|
upower_glib = upowerSupport;
|
||||||
|
wireplumber = wireplumberSupport;
|
||||||
|
}
|
||||||
|
) ++ [
|
||||||
|
"-Dsystemd=disabled"
|
||||||
|
"-Dgtk-layer-shell=enabled"
|
||||||
|
"-Dman-pages=enabled"
|
||||||
|
"-Dcava=disabled"
|
||||||
|
"-Dexperimental=true"
|
||||||
|
];
|
||||||
|
|
||||||
|
preFixup = lib.optionalString withMediaPlayer ''
|
||||||
|
cp $src/resources/custom_modules/mediaplayer.py $out/bin/waybar-mediaplayer.py
|
||||||
|
|
||||||
|
wrapProgram $out/bin/waybar-mediaplayer.py \
|
||||||
|
--prefix PYTHONPATH : "$PYTHONPATH:$out/${python3.sitePackages}"
|
||||||
|
'';
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
changelog = "https://github.com/alexays/waybar/releases/tag/${version}";
|
||||||
|
description = "Highly customizable Wayland bar for Sway and Wlroots based compositors";
|
||||||
|
license = licenses.mit;
|
||||||
|
maintainers = with maintainers; [ FlorianFranzen minijackson synthetica lovesegfault rodrgz ];
|
||||||
|
platforms = platforms.unix;
|
||||||
|
homepage = "https://github.com/alexays/waybar";
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user