diff --git a/common.nix b/common.nix index 97fc5ce..cf941b1 100644 --- a/common.nix +++ b/common.nix @@ -86,10 +86,59 @@ in config.services.avahi.enable = true; config.services.avahi.nssmdns = true; + config.services.blueman.enable = true; #bluetooth + + config.services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + # If you want to use JACK applications, uncomment this + #jack.enable = true; + + # use the example session manager (no others are packaged yet so this is enabled by default, + # no need to redefine it in your config for now) + #media-session.enable = true; + media-session.config.bluez-monitor.rules = [ + { + # Matches all cards + matches = [ { "device.name" = "~bluez_card.*"; } ]; + actions = { + "update-props" = { + "bluez5.reconnect-profiles" = [ "hfp_hf" "hsp_hs" "a2dp_sink" ]; + # mSBC is not expected to work on all headset + adapter combinations. + "bluez5.msbc-support" = true; + # SBC-XQ is not expected to work on all headset + adapter combinations. + "bluez5.sbc-xq-support" = true; + }; + }; + } + { + matches = [ + # Matches all sources + { "node.name" = "~bluez_input.*"; } + # Matches all outputs + { "node.name" = "~bluez_output.*"; } + ]; + actions = { + "node.pause-on-idle" = false; + }; + } + ]; + }; + # Enable sound. config.sound.enable = true; config.hardware = { - pulseaudio.enable = true; + + bluetooth = { + enable = true; + settings = { + General = { + Enable = "Source,Sink,Media,Socket"; + }; + }; + }; sane = { enable = true; diff --git a/desktops/default-desktop.nix b/desktops/default-desktop.nix index a328d3a..72bf7d1 100644 --- a/desktops/default-desktop.nix +++ b/desktops/default-desktop.nix @@ -6,6 +6,13 @@ let fetchTarball https://github.com/NixOS/nixpkgs/archive/nixos-unstable.tar.gz ){ config = { allowUnfree = true; }; }; + i3lock-pixeled-fixed = pkgs.i3lock-pixeled.overrideDerivation (oldAttrs: rec { + patchPhase = oldAttrs.patchPhase + '' + substituteInPlace i3lock-pixeled \ + --replace '# take the actual screenshot' 'rm $IMGFILE 2> /dev/null' + ''; + }); + in { services = { # For checking power status @@ -23,8 +30,8 @@ in { extraPackages = with pkgs; [ dmenu feh - i3lock-pixeled-fixed i3status + i3lock-pixeled-fixed polybarFull rofi ]; diff --git a/users/kczulko/config-files/.config/i3/config b/users/kczulko/config-files/.config/i3/config index 0edd4c5..de68640 100644 --- a/users/kczulko/config-files/.config/i3/config +++ b/users/kczulko/config-files/.config/i3/config @@ -21,6 +21,8 @@ exec --no-startup-id sh ~/.screenlayout/setup.sh # NetworkManager is the most popular way to manage wireless networks on Linux, # and nm-applet is a desktop environment-independent system tray GUI for it. exec --no-startup-id nm-applet +# blueman-applet for bluetooth devices mgmt +exec --no-startup-id blueman-applet # Use Mouse+$mod to drag floating windows to their wanted position floating_modifier $mod diff --git a/users/kczulko/user-profile.nix b/users/kczulko/user-profile.nix index da11e81..2551a9e 100644 --- a/users/kczulko/user-profile.nix +++ b/users/kczulko/user-profile.nix @@ -11,13 +11,6 @@ let sbtJava8 = pkgs.sbt.override { jre = pkgs.openjdk8; }; - i3lock-pixeled-fixed = pkgs.i3lock-pixeled.overrideDerivation (oldAttrs: rec { - patchPhase = oldAttrs.patchPhase + '' - substituteInPlace i3lock-pixeled \ - --replace '# take the actual screenshot' 'rm $IMGFILE 2> /dev/null' - ''; - }); - # cannot build derivation unstable.metals due to hash issues metalsJava8 = pkgs.metals.override { jdk = pkgs.openjdk8; jre = pkgs.openjdk8; }; bloopJava8 = pkgs.bloop.override { jre = pkgs.openjdk8; }; @@ -69,11 +62,13 @@ in { customizations.polybar-launcher customizations.setup-resolution evince + noisetorch gnome3.gnome-screenshot gscan2pdf ispell metalsJava8 nix-prefetch-git + openconnect openjdk8 sbtJava8 slack-dark diff --git a/workstation.nix b/workstation.nix index 1d552c3..c83cf6a 100644 --- a/workstation.nix +++ b/workstation.nix @@ -20,6 +20,10 @@ boot.zfs.requestEncryptionCredentials = true; boot.supportedFilesystems = [ "zfs" ]; + # enable virtualisation + #virtualisation.virtualbox.host.enable = true; + #users.extraGroups.vboxusers.members = [ "kczulko" ]; + networking = { useDHCP = false;