diff options
| author | Quentin Aristote <quentin@aristote.fr> | 2023-03-01 13:50:55 +0100 |
|---|---|---|
| committer | Quentin Aristote <quentin@aristote.fr> | 2023-03-01 14:03:57 +0100 |
| commit | 21034a5a36d62fbad795c4139c98c32e0516ec93 (patch) | |
| tree | db063cbb3e91bf7231c0eb54fb54b3cb5ac51dfe /modules/home-manager/personal | |
| parent | ceb6a8075e1b6e1228b7c75a8da36ed520d32b5f (diff) | |
restructure pkgs
Diffstat (limited to 'modules/home-manager/personal')
| -rw-r--r-- | modules/home-manager/personal/dotfiles/background-image | bin | 581223 -> 0 bytes | |||
| -rw-r--r-- | modules/home-manager/personal/dotfiles/default.nix | 1 | ||||
| -rw-r--r-- | modules/home-manager/personal/environment.nix | 7 | ||||
| -rw-r--r-- | modules/home-manager/personal/gui/x/i3/startup.nix | 3 | ||||
| -rw-r--r-- | modules/home-manager/personal/profiles.nix | 6 | ||||
| -rw-r--r-- | modules/home-manager/personal/programs/firefox/default.nix | 4 | ||||
| -rw-r--r-- | modules/home-manager/personal/programs/firefox/userjs.nix | 124 | ||||
| -rw-r--r-- | modules/home-manager/personal/programs/git.nix | 2 | ||||
| -rw-r--r-- | modules/home-manager/personal/programs/thunderbird.nix | 2 |
9 files changed, 73 insertions, 76 deletions
diff --git a/modules/home-manager/personal/dotfiles/background-image b/modules/home-manager/personal/dotfiles/background-image Binary files differdeleted file mode 100644 index 4288f3e..0000000 --- a/modules/home-manager/personal/dotfiles/background-image +++ /dev/null diff --git a/modules/home-manager/personal/dotfiles/default.nix b/modules/home-manager/personal/dotfiles/default.nix index 27610ca..bccd4f8 100644 --- a/modules/home-manager/personal/dotfiles/default.nix +++ b/modules/home-manager/personal/dotfiles/default.nix @@ -2,7 +2,6 @@ { personal.home.dotfiles = { - wallpaper = ./background-image; latexmkrc = ./latexmkrc; rofi = ./rofi.rasi; spacemacs = ./spacemacs.el; diff --git a/modules/home-manager/personal/environment.nix b/modules/home-manager/personal/environment.nix index 3d29db1..7518c33 100644 --- a/modules/home-manager/personal/environment.nix +++ b/modules/home-manager/personal/environment.nix @@ -2,11 +2,10 @@ { home.packages = with pkgs; [ coreutils moreutils ]; - personal.home.wallpaper = lib.mkDefault config.personal.home.dotfiles.wallpaper; + personal.home.wallpaper = + lib.mkDefault pkgs.personal.static.wallpapers.nga-1973-68-1; - programs.bash = { - enable = lib.mkDefault true; - }; + programs.bash = { enable = lib.mkDefault true; }; home = { shellAliases = { diff --git a/modules/home-manager/personal/gui/x/i3/startup.nix b/modules/home-manager/personal/gui/x/i3/startup.nix index 9baf388..b40247b 100644 --- a/modules/home-manager/personal/gui/x/i3/startup.nix +++ b/modules/home-manager/personal/gui/x/i3/startup.nix @@ -15,9 +15,6 @@ # ++ autostartIf config.services.redshift.enable { # command = "systemctl --user start redshift"; # } - ++ autostartIf (config.personal.home.wallpaper != null) { - command = "${pkgs.feh}/bin/feh --bg-scale ${config.personal.home.wallpaper}"; - } # ++ autostartIf config.services.xidlehook.enable { # command = "systemctl --user start xidlehook.service"; # } diff --git a/modules/home-manager/personal/profiles.nix b/modules/home-manager/personal/profiles.nix index 25722f5..5aad4a4 100644 --- a/modules/home-manager/personal/profiles.nix +++ b/modules/home-manager/personal/profiles.nix @@ -51,7 +51,7 @@ in { { name = "Netflix"; genericName = "Streaming service"; - icon = "${pkgs.personal.netflixIcon}"; + icon = "${pkgs.personal.static.icons.netflix}"; comment = "Unlimited movies, TV shows, and more."; url = "https://www.netflix.com/fr-en/login"; categories = [ "AudioVideo" "Video" "Player" ]; @@ -59,7 +59,7 @@ in { { name = "MUBI"; genericName = "Streaming service"; - icon = "${pkgs.personal.mubiIcon}"; + icon = "${pkgs.personal.static.icons.mubi}"; comment = "Watch hand-picked cinema."; url = "https://mubi.com"; categories = [ "AudioVideo" "Video" "Player" ]; @@ -67,7 +67,7 @@ in { { name = "Deezer"; genericName = "Streaming service"; - icon = "${pkgs.personal.deezerIcon}"; + icon = "${pkgs.personal.static.icons.deezer}"; comment = "Listen to music online"; url = "https://deezer.com/login"; categories = [ "AudioVideo" "Audio" "Player" "Music" ]; diff --git a/modules/home-manager/personal/programs/firefox/default.nix b/modules/home-manager/personal/programs/firefox/default.nix index 1e97c40..f4696b1 100644 --- a/modules/home-manager/personal/programs/firefox/default.nix +++ b/modules/home-manager/personal/programs/firefox/default.nix @@ -4,7 +4,7 @@ with lib; let cfg = config.personal.firefox; userjs = pkgs.callPackage ./userjs.nix { - inherit (pkgs.personal) arkenfoxUserJS; + inherit (pkgs.personal.static.userjs) arkenfox; inherit (pkgs.lib.personal) toUserJS; }; engines = import ./engines.nix; @@ -23,7 +23,7 @@ let visibility: collapse; } ''; - extensions = with pkgs.personal; [ + extensions = with pkgs.personal.firefoxAddons; [ canvasblocker clearurls darkreader diff --git a/modules/home-manager/personal/programs/firefox/userjs.nix b/modules/home-manager/personal/programs/firefox/userjs.nix index ee105b3..75780ee 100644 --- a/modules/home-manager/personal/programs/firefox/userjs.nix +++ b/modules/home-manager/personal/programs/firefox/userjs.nix @@ -1,66 +1,68 @@ -{ arkenfoxUserJS, toUserJS }: +{ arkenfox, toUserJS }: -rec { - arkenfox = builtins.readFile "${arkenfoxUserJS}"; - default = arkenfox + toUserJS { - "keyword.enabled" = true; # 0801 - "signon.rememberSignons" = false; # 0901 - "security.nocertdb" = true; # 1222 - "media.peerconnection.enabled" = false; # 2001 - "media.peerconnection.ice.no_host" = true; # 2004 - "dom.allow_cut_copy" = true; # 2404 - "dom.battery.enabled" = false; # 2502 - "permissions.default.xr" = 2; # 2521 - "privacy.clearOnShutdown.siteSettings" = true; # 2811 +let + self = { + arkenfox = builtins.readFile "${arkenfox}"; + default = self.arkenfox + toUserJS { + "keyword.enabled" = true; # 0801 + "signon.rememberSignons" = false; # 0901 + "security.nocertdb" = true; # 1222 + "media.peerconnection.enabled" = false; # 2001 + "media.peerconnection.ice.no_host" = true; # 2004 + "dom.allow_cut_copy" = true; # 2404 + "dom.battery.enabled" = false; # 2502 + "permissions.default.xr" = 2; # 2521 + "privacy.clearOnShutdown.siteSettings" = true; # 2811 - # Personal - ## Warnings - "browser.tabs.warnOnClose" = false; - "browser.tabs.warnOnCloseOtherTabs" = false; - ## Updates - "app.update.auto" = false; - "browser.search.update" = false; - ## Appearance - "toolkit.legacyUserProfileCustomizations.stylesheets" = true; - ## Content behavior - "clipboard.autocopy" = false; - ## UX behavior - "browser.quitShortcut.disabled" = true; - "browser.tabs.closeWindowWithLastTab" = false; - ## UX features - "extensions.pocket.enabled" = false; - "identity.fxaccounts.enabled" = false; - }; + # Personal + ## Warnings + "browser.tabs.warnOnClose" = false; + "browser.tabs.warnOnCloseOtherTabs" = false; + ## Updates + "app.update.auto" = false; + "browser.search.update" = false; + ## Appearance + "toolkit.legacyUserProfileCustomizations.stylesheets" = true; + ## Content behavior + "clipboard.autocopy" = false; + ## UX behavior + "browser.quitShortcut.disabled" = true; + "browser.tabs.closeWindowWithLastTab" = false; + ## UX features + "extensions.pocket.enabled" = false; + "identity.fxaccounts.enabled" = false; + }; - streaming = default + toUserJS { - # Widevine (DRMs) - "media.gmp-widevinecdm.enabled" = true; - "media.eme.enabled" = true; - # Cache - "browser.cache.disk.enable" = true; - "browser.cache.offline.storage" = true; - # Privacy - "privacy.clearOnShutdown.cache" = false; - "privacy.clearOnShutdown.cookies" = false; - "privacy.clearOnShutdown.siteSettings" = false; - "privacy.clearOnShutdown.offlineApps" = false; - "privacy.resistFingerprinting" = false; # Netflix is whining - }; + streaming = self.default + toUserJS { + # Widevine (DRMs) + "media.gmp-widevinecdm.enabled" = true; + "media.eme.enabled" = true; + # Cache + "browser.cache.disk.enable" = true; + "browser.cache.offline.storage" = true; + # Privacy + "privacy.clearOnShutdown.cache" = false; + "privacy.clearOnShutdown.cookies" = false; + "privacy.clearOnShutdown.siteSettings" = false; + "privacy.clearOnShutdown.offlineApps" = false; + "privacy.resistFingerprinting" = false; # Netflix is whining + }; - videoconferencing = default + toUserJS { - # IMPORTANT: uncheck "Prevent WebRTC from leaking local IP addresses" in uBlock Origin's settings - # NOTE: if using RFP (4501) - # some sites, e.g. Zoom, need a canvas site exception [Right Click>View Page Info>Permissions] - # Discord video does not work: it thinks you are FF78: use a separate profile or spoof the user agent - "media.peerconnection.enabled" = true; - "media.peerconnection.ice.no_host" = false; # may or may not be required - "webgl.disabled" = false; # required for Zoom - "webgl.min_capability_mode" = false; - "media.getusermedia.screensharing.enabled" = true; # optional - "media.autoplay.blocking_policy" = - 0; # optional (otherwise add site exceptions) - "javascript.options.wasm" = - true; # optional (some platforms may require this) - "dom.webaudio.enabled" = true; + videoconferencing = self.default + toUserJS { + # IMPORTANT: uncheck "Prevent WebRTC from leaking local IP addresses" in uBlock Origin's settings + # NOTE: if using RFP (4501) + # some sites, e.g. Zoom, need a canvas site exception [Right Click>View Page Info>Permissions] + # Discord video does not work: it thinks you are FF78: use a separate profile or spoof the user agent + "media.peerconnection.enabled" = true; + "media.peerconnection.ice.no_host" = false; # may or may not be required + "webgl.disabled" = false; # required for Zoom + "webgl.min_capability_mode" = false; + "media.getusermedia.screensharing.enabled" = true; # optional + "media.autoplay.blocking_policy" = + 0; # optional (otherwise add site exceptions) + "javascript.options.wasm" = + true; # optional (some platforms may require this) + "dom.webaudio.enabled" = true; + }; }; -} +in self diff --git a/modules/home-manager/personal/programs/git.nix b/modules/home-manager/personal/programs/git.nix index 5d272dc..578f6a7 100644 --- a/modules/home-manager/personal/programs/git.nix +++ b/modules/home-manager/personal/programs/git.nix @@ -6,7 +6,7 @@ userEmail = lib.mkDefault "quentin@aristote.fr"; ignores = builtins.map builtins.readFile - (with pkgs.personal; [ emacsGitignore linuxGitignore direnvGitignore ]) + (with pkgs.personal.static.gitignore; [ direnv emacs linux ]) ++ [ # Personal rules '' diff --git a/modules/home-manager/personal/programs/thunderbird.nix b/modules/home-manager/personal/programs/thunderbird.nix index c3450af..e971e5a 100644 --- a/modules/home-manager/personal/programs/thunderbird.nix +++ b/modules/home-manager/personal/programs/thunderbird.nix @@ -1,7 +1,7 @@ { config, lib, pkgs, ... }: let - configDefault = builtins.readFile "${pkgs.personal.thunderbirdUserJS}" + configDefault = builtins.readFile "${pkgs.personal.static.userjs.thunderbird}" + pkgs.lib.personal.toUserJS { # 0391 "mail.bii.alert.show_preview" = false; |
