mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
adw-bluetooth: 1.0.0 -> 1.1.0
This commit is contained in:
parent
3b5ec87c52
commit
7d6b363b76
2 changed files with 56 additions and 5 deletions
33
nixos/modules/services/desktops/adw-bluetooth.nix
Normal file
33
nixos/modules/services/desktops/adw-bluetooth.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
cfg = config.services.adw-bluetooth;
|
||||
in
|
||||
{
|
||||
meta.maintainers = with lib.maintainers; [ ezratweaver ];
|
||||
|
||||
options.services.adw-bluetooth = {
|
||||
enable = lib.mkEnableOption "Adwaita Bluetooth daemon";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
environment.systemPackages = [ pkgs.adw-bluetooth ];
|
||||
services.dbus.packages = [ pkgs.adw-bluetooth ];
|
||||
|
||||
systemd.user.services.adw-bluetooth-daemon = {
|
||||
description = "AdwBluetooth Daemon";
|
||||
wantedBy = [ "default.target" ];
|
||||
after = [ "bluetooth.target" ];
|
||||
serviceConfig = {
|
||||
Type = "dbus";
|
||||
BusName = "com.ezratweaver.AdwBluetoothDaemon";
|
||||
ExecStart = "${pkgs.adw-bluetooth}/libexec/adw-bluetooth-daemon";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -2,6 +2,7 @@
|
|||
stdenv,
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
buildGoModule,
|
||||
meson,
|
||||
ninja,
|
||||
pkg-config,
|
||||
|
|
@ -13,17 +14,27 @@
|
|||
libadwaita,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "adw-bluetooth";
|
||||
version = "1.0.0";
|
||||
let
|
||||
version = "1.1.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ezratweaver";
|
||||
repo = "adw-bluetooth";
|
||||
tag = finalAttrs.version;
|
||||
hash = "sha256-/KJpB9i6tFDnB3C0tPtJtt8tTDfNftIkHmP1JSVSZNY=";
|
||||
tag = version;
|
||||
hash = "sha256-h3cHtecwBsx3j33qXVn/zaq4FZext71P7flzunCHqHg=";
|
||||
};
|
||||
|
||||
daemon = buildGoModule {
|
||||
pname = "adw-bluetooth-daemon";
|
||||
inherit version;
|
||||
src = src + "/daemon";
|
||||
vendorHash = "sha256-7tiSwNhq6e4LEh4lUkfh2i4tEdWWL6TxQpYYwYKsfog=";
|
||||
};
|
||||
in
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "adw-bluetooth";
|
||||
inherit version src;
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson
|
||||
ninja
|
||||
|
|
@ -39,6 +50,13 @@ stdenv.mkDerivation (finalAttrs: {
|
|||
libadwaita
|
||||
];
|
||||
|
||||
mesonFlags = [ "-Dbuild_daemon=false" ];
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/libexec
|
||||
ln -s ${daemon}/bin/daemon $out/libexec/adw-bluetooth-daemon
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "GNOME Inspired LibAdwaita Bluetooth Applet";
|
||||
homepage = "https://github.com/ezratweaver/adw-bluetooth";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue