diff options
Diffstat (limited to '')
| -rw-r--r-- | flake.lock | 32 | ||||
| -rw-r--r-- | home/apps/caelestia/settings.nix | 6 | ||||
| -rw-r--r-- | home/apps/default.nix | 1 | ||||
| -rw-r--r-- | home/apps/kanshi.nix | 53 | ||||
| -rw-r--r-- | home/browsers/firefox/default.nix | 2 | ||||
| -rw-r--r-- | home/browsers/firefox/extensions.nix | 6 | ||||
| -rw-r--r-- | home/browsers/firefox/policies.nix | 9 | ||||
| -rw-r--r-- | home/browsers/firefox/prefs.nix | 52 | ||||
| -rw-r--r-- | hosts/shinji/default.nix | 4 | ||||
| -rw-r--r-- | options.nix | 6 |
10 files changed, 146 insertions, 25 deletions
@@ -116,11 +116,11 @@ ] }, "locked": { - "lastModified": 1769024061, - "narHash": "sha256-7KC8OYI4wsIH+gP+9Var4FILL2qkJi3cIOrjRO5OaUw=", + "lastModified": 1769179160, + "narHash": "sha256-DjfxMxf38u0UYrMs3pMzT3sv4v3JsbwHo09vVNM3ctk=", "ref": "refs/heads/main", - "rev": "2c0dd689145e48e9d3683dfd3556723895fa54aa", - "revCount": 1736, + "rev": "56cf4be7499a93efdb30cbe408334d48011a55e1", + "revCount": 1762, "type": "git", "url": "https://g.freya.cat/caelestia-shell" }, @@ -258,11 +258,11 @@ ] }, "locked": { - "lastModified": 1769015285, - "narHash": "sha256-MlqzCJbckJsgwfkRs64H2xaX2Uxl4o6Z9XYfkYS1N/E=", + "lastModified": 1769132734, + "narHash": "sha256-gmU9cRplrQWqoback9PgQX7Dlsdx8JlhlVZwf0q1F7E=", "owner": "nix-community", "repo": "home-manager", - "rev": "ec0247a7a19f641595c24ac1ea4df6461d1cdb36", + "rev": "d055b309a6277343cb1033a11d7500f0a0f669fc", "type": "github" }, "original": { @@ -670,11 +670,11 @@ }, "nixos-hardware": { "locked": { - "lastModified": 1768736227, - "narHash": "sha256-qgGq7CfrYKc3IBYQ7qp0Z/ZXndQVC5Bj0N8HW9mS2rM=", + "lastModified": 1769086393, + "narHash": "sha256-3ymIZ8s3+hu7sDl/Y48o6bwMxorfKrmn97KuWiw1vjY=", "owner": "nixos", "repo": "nixos-hardware", - "rev": "d447553bcbc6a178618d37e61648b19e744370df", + "rev": "9f7ba891ea5fc3ededd7804f1a23fafadbcb26ca", "type": "github" }, "original": { @@ -707,11 +707,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1768886240, - "narHash": "sha256-C2TjvwYZ2VDxYWeqvvJ5XPPp6U7H66zeJlRaErJKoEM=", + "lastModified": 1769018530, + "narHash": "sha256-MJ27Cy2NtBEV5tsK+YraYr2g851f3Fl1LpNHDzDX15c=", "owner": "nixos", "repo": "nixpkgs", - "rev": "80e4adbcf8992d3fd27ad4964fbb84907f9478b0", + "rev": "88d3861acdd3d2f0e361767018218e51810df8a1", "type": "github" }, "original": { @@ -1112,11 +1112,11 @@ ] }, "locked": { - "lastModified": 1768999995, - "narHash": "sha256-7OXxa5rG+GeUL0iYkAbpVKFW/QPcThmlZMJufYOiwdc=", + "lastModified": 1769059766, + "narHash": "sha256-u95Qe60mF3eoEqrd0tIej4A8TDWoc/N4ZjZ60npplgw=", "owner": "0xc000022070", "repo": "zen-browser-flake", - "rev": "13f0273a63b054c4e6de04f0fc838e18f1bf28e7", + "rev": "dc0483a6e3ff1ffb04ad77d26c1a4458f4cf82d6", "type": "github" }, "original": { diff --git a/home/apps/caelestia/settings.nix b/home/apps/caelestia/settings.nix index c116025..de81df7 100644 --- a/home/apps/caelestia/settings.nix +++ b/home/apps/caelestia/settings.nix @@ -83,6 +83,12 @@ in { }; }; + # Launcher settings + launcher = { + enabled = true; + useFuzzy = true; + }; + # Background background.enabled = true; paths = { 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 d251ae1..724f286 100644 --- a/home/browsers/firefox/default.nix +++ b/home/browsers/firefox/default.nix @@ -35,7 +35,7 @@ in { profiles.${config.user} = { search = { force = true; - default = "ddg"; + default = "noai"; }; inherit userChrome; diff --git a/home/browsers/firefox/extensions.nix b/home/browsers/firefox/extensions.nix index e8d6e2c..8eade0d 100644 --- a/home/browsers/firefox/extensions.nix +++ b/home/browsers/firefox/extensions.nix @@ -41,4 +41,10 @@ install_url = "https://www.mrfdev.com/downloads/enhancer_for_youtube-2.0.130.1.xpi"; installation_mode = "force_installed"; }; + + # Indie Wiki Buddy + "{cb31ec5d-c49a-4e5a-b240-16c767444f62}" = { + install_url = "https://addons.mozilla.org/firefox/downloads/latest/indie-wiki-buddy/latest.xpi"; + installation_mode = "force_installed"; + }; } diff --git a/home/browsers/firefox/policies.nix b/home/browsers/firefox/policies.nix index b8e8623..52b188c 100644 --- a/home/browsers/firefox/policies.nix +++ b/home/browsers/firefox/policies.nix @@ -134,8 +134,9 @@ # Search Engines SearchEngines = { - Default = "DuckDuckGo"; + Default = "noai"; Remove = [ + "DuckDuckGo" "Google" "Amazon.com" "Bing" @@ -143,6 +144,12 @@ "Wikipedia (en)" "Perplexity" ]; + Add = [ + { + Name = "noai"; + URLTemplate = "https://noai.duckduckgo.com/?q={searchTerms}"; + } + ]; }; # Miscellaneous diff --git a/home/browsers/firefox/prefs.nix b/home/browsers/firefox/prefs.nix index 73d2781..123dc4b 100644 --- a/home/browsers/firefox/prefs.nix +++ b/home/browsers/firefox/prefs.nix @@ -56,11 +56,19 @@ in { "browser.urlbar.suggest.openpage" = lock-false; "browser.urlbar.suggest.pocket" = lock-false; "browser.urlbar.suggest.remotetab" = lock-false; + "browser.urlbar.suggest.quickactions" = lock-false; "browser.urlbar.suggest.topsites" = lock-false; "browser.urlbar.suggest.trending" = lock-false; "browser.urlbar.suggest.weather" = lock-false; "browser.urlbar.suggest.yelp" = lock-false; + # search suggestions + "browser.search.suggest.enabled" = lock-true; + "browser.search.suggest.enabled.private" = lock-false; + + # remember history + "places.history.enabled" = lock-true; + # privacy "privacy.globalprivacycontrol.enabled" = lock-true; @@ -116,13 +124,47 @@ in { "browser.tabs.closeTabByDblclick" = lock-true; "ui.key.menuAccessKeyFocuses" = lock-false; + # open links in tabs not new windows + "browser.link.open_newwindow" = { + Value = 3; + Status = "locked"; + }; + + # load images in new tab, dont switch immediately + "browser.link.open_newwindow.override.external" = { + Value = -1; + Status = "locked"; + }; + + # open previous tabs on start + "browser.startup.page" = { + Value = 3; + Status = "locked"; + }; + # general settings - "general.autoScroll" = lock-false; - "general.smoothScroll" = lock-true; - "widget.gtk.overlay-scrollbars.enabled" = lock-false; "accessibility.browsewithcaret" = lock-false; "accessibility.typeaheadfind" = lock-false; - "media.hardwaremediakeys.enabled" = lock-true; - "browser.crashReports.unsubmittedCheck.autoSubmit2" = lock-false; "browser.aboutConfig.showWarning" = lock-false; + "browser.crashReports.unsubmittedCheck.autoSubmit2" = lock-false; + "browser.ctrlTab.sortByRecentlyUsed" = lock-false; + "browser.display.document_color_use" = { + Value = 1; # disable contrast controll + Status = "locked"; + }; + "browser.ml.linkPreview.enabled" = lock-false; + "browser.privatebrowsing.autostart" = lock-false; + "browser.tabs.hoverPreview.showThumbnails" = lock-true; + "browser.tabs.loadInBackground" = lock-true; + "browser.warnOnQuitShortcut" = lock-true; + "browser.zoom.full" = lock-true; + "general.autoScroll" = lock-false; + "general.smoothScroll" = lock-true; + "layout.css.always_underline_links" = lock-false; + "layout.spellcheckDefault" = { + Value = 1; + Status = "locked"; + }; + "media.hardwaremediakeys.enabled" = lock-true; + "widget.gtk.overlay-scrollbars.enabled" = lock-false; } diff --git a/hosts/shinji/default.nix b/hosts/shinji/default.nix index ec86418..4062082 100644 --- a/hosts/shinji/default.nix +++ b/hosts/shinji/default.nix @@ -17,6 +17,7 @@ monitors = [ { port = "eDP-1"; + laptop = true; scale = 1.25; bitdepth = 10; } @@ -42,8 +43,6 @@ # set power btn to suspend services.logind.settings.Login = { HandlePowerKey = "suspend"; - HandeLidSwitch = "suspend"; - HandeLidSwitchDocked = "suspend"; }; # logitech mouse udev @@ -70,6 +69,7 @@ caelestia.enable = true; hyprlock.enable = true; rofi.enable = true; + kanshi.enable = true; kitty.enable = true; }; browsers = { diff --git a/options.nix b/options.nix index c80cdfd..241f726 100644 --- a/options.nix +++ b/options.nix @@ -19,6 +19,11 @@ with lib; let default = ""; }; + laptop = mkEnableOption { + description = "Flags this monitor to be part of a laptop and not docked."; + default = false; + }; + position = { enabled = mkEnableOption { description = "Enables hardcoded position of the monitor."; @@ -473,6 +478,7 @@ in { apps = { alacritty.enable = mkEnableOption "Enable the alacritty terminal."; astal.enable = mkEnableOption "Enable the astal gtk shell."; + kanshi.enable = mkEnableOption "Enable the kanshi service."; kitty.enable = mkEnableOption "Enable the kitty terminal."; mako.enable = mkEnableOption "Enable the mako notification daemon."; hyprlock.enable = mkEnableOption "Enable the hyprlock lockscreen."; |