summaryrefslogtreecommitdiff
path: root/home
diff options
context:
space:
mode:
Diffstat (limited to 'home')
-rw-r--r--home/apps/caelestia/settings.nix5
-rw-r--r--home/apps/default.nix1
-rw-r--r--home/apps/kanshi.nix53
-rw-r--r--home/browsers/firefox/default.nix7
-rw-r--r--home/desktops/hyprland/settings.nix4
5 files changed, 64 insertions, 6 deletions
diff --git a/home/apps/caelestia/settings.nix b/home/apps/caelestia/settings.nix
index a529241..c116025 100644
--- a/home/apps/caelestia/settings.nix
+++ b/home/apps/caelestia/settings.nix
@@ -81,11 +81,6 @@ in {
audio = ["pavucontrol"];
playback = ["mpv"];
};
- # disable lock screen
- idle = {
- lockBeforeSleep = false;
- timeouts = [];
- };
};
# Background
diff --git a/home/apps/default.nix b/home/apps/default.nix
index 1823b0d..baf9d82 100644
--- a/home/apps/default.nix
+++ b/home/apps/default.nix
@@ -7,6 +7,7 @@ _: {
./alacritty.nix
./astal.nix
./hyprlock.nix
+ ./kanshi.nix
./kitty.nix
./mako.nix
];
diff --git a/home/apps/kanshi.nix b/home/apps/kanshi.nix
new file mode 100644
index 0000000..ed7622a
--- /dev/null
+++ b/home/apps/kanshi.nix
@@ -0,0 +1,53 @@
+{
+ config,
+ lib,
+ ...
+}: let
+ inherit (lib) mkIf;
+ cfg = config.apps.kanshi;
+
+ laptopMonitors = lib.lists.filter (mon: mon.laptop) config.monitors;
+ dockedMonitors = lib.lists.filter (mon: !mon.laptop) config.monitors;
+
+ mkOutput = mon: status:
+ lib.mkMerge [
+ {
+ criteria =
+ if mon.desc == ""
+ then mon.port
+ else mon.desc;
+ scale = mon.scale;
+ inherit status;
+ }
+ (lib.mkIf (mon.position.x != 0 || mon.position.y != 0) {
+ position = "${toString mon.position.x},${toString mon.position.y}";
+ })
+ (lib.mkIf (mon.size.x != 0 && mon.size.y != 0) {
+ mode = "${toString mon.size.x}x${toString mon.size.y}";
+ })
+ ];
+
+ mkEnabledOutput = mon: (mkOutput mon "enable");
+ mkDisabledOutput = mon: (mkOutput mon "disable");
+in {
+ config = mkIf cfg.enable {
+ services.kanshi = {
+ enable = true;
+
+ settings = [
+ {
+ profile = {
+ name = "laptop";
+ outputs = map mkEnabledOutput laptopMonitors;
+ };
+ }
+ {
+ profile = {
+ name = "docked";
+ outputs = (map mkEnabledOutput dockedMonitors) ++ (map mkDisabledOutput laptopMonitors);
+ };
+ }
+ ];
+ };
+ };
+}
diff --git a/home/browsers/firefox/default.nix b/home/browsers/firefox/default.nix
index 578efe4..d251ae1 100644
--- a/home/browsers/firefox/default.nix
+++ b/home/browsers/firefox/default.nix
@@ -16,7 +16,12 @@ in {
config = mkIf cfg.enable {
default.browser = lib.mkDefault "firefox";
- programs.firefox = rec {
+ mozilla = {
+ firefoxNativeMessagingHosts = lib.mkForce [];
+ thunderbirdNativeMessagingHosts = lib.mkForce [];
+ };
+
+ programs.firefox = {
enable = true;
package = my-firefox;
diff --git a/home/desktops/hyprland/settings.nix b/home/desktops/hyprland/settings.nix
index d285b04..5458dc8 100644
--- a/home/desktops/hyprland/settings.nix
+++ b/home/desktops/hyprland/settings.nix
@@ -111,6 +111,7 @@
# Layer rules
layerrule = [
+ # fix weird borders
"blur true, match:namespace wofi"
"ignore_alpha 0, match:namespace wofi"
"blur true, match:namespace notificaations"
@@ -119,6 +120,9 @@
"ignore_alpha 0, match:namespace swaync-notification-window"
"blur true, match:namespace swaync-control-center"
"ignore_alpha 0, match:namespace swaync-control-center"
+
+ # dont animate slurp
+ "no_anim true, match:namespace selection"
];
# XWayland