mirror of
https://github.com/RGBCube/ncc
synced 2025-08-03 05:27:46 +00:00
zen: try to fix it but realize it doesn't work
This commit is contained in:
parent
91f3d03ea3
commit
4aa90bb98f
5 changed files with 94 additions and 58 deletions
|
@ -11,7 +11,7 @@ inputs: self: super: let
|
||||||
|> filter (hasAttrByPath path)
|
|> filter (hasAttrByPath path)
|
||||||
|> map (getAttrFromPath path);
|
|> map (getAttrFromPath path);
|
||||||
|
|
||||||
inputHomeModules = collectInputs [ "homeModules" "default" ];
|
inputHomeModules = collectInputs [ "homeModules" "default" ];
|
||||||
inputModulesLinux = collectInputs [ "nixosModules" "default" ];
|
inputModulesLinux = collectInputs [ "nixosModules" "default" ];
|
||||||
inputModulesDarwin = collectInputs [ "darwinModules" "default" ];
|
inputModulesDarwin = collectInputs [ "darwinModules" "default" ];
|
||||||
|
|
||||||
|
|
|
@ -1,63 +1,100 @@
|
||||||
{ lib, ... }: let
|
{ lib, ... }: let
|
||||||
inherit (lib) enabled merge;
|
inherit (lib) enabled;
|
||||||
|
|
||||||
lockedAs = Value: merge {
|
lockedAs = Value: attrs: attrs // {
|
||||||
inherit Value;
|
inherit Value;
|
||||||
Locked = true;
|
Locked = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
locked = merge { Locked = true; };
|
locked = attrs: attrs // { Locked = true; };
|
||||||
|
|
||||||
|
policies = {
|
||||||
|
AutofillAddressEnabled = false;
|
||||||
|
AutofillCreditCardEnabled = false;
|
||||||
|
|
||||||
|
DisableAppUpdate = true;
|
||||||
|
AppAutoUpdate = false;
|
||||||
|
BackgroundAppUpdate = false;
|
||||||
|
|
||||||
|
DisableFeedbackCommands = true;
|
||||||
|
DisableFirefoxStudies = true;
|
||||||
|
DisablePocket = true;
|
||||||
|
DisableTelemetry = true;
|
||||||
|
DisableProfileImport = true;
|
||||||
|
DisableProfileRefresh = true;
|
||||||
|
|
||||||
|
BlockAboutConfig = false;
|
||||||
|
BlockAboutProfiles = true;
|
||||||
|
BlockAboutSupport = true;
|
||||||
|
|
||||||
|
# We want it to be the default browser.
|
||||||
|
DontCheckDefaultBrowser = false;
|
||||||
|
|
||||||
|
NoDefaultBookmarks = true;
|
||||||
|
|
||||||
|
# I accept the terms of use.
|
||||||
|
SkipTermsOfUse = true;
|
||||||
|
|
||||||
|
PictureInPicture = lockedAs false {};
|
||||||
|
|
||||||
|
Homepage = locked { StartPage = "previous-session"; };
|
||||||
|
|
||||||
|
EnableTrackingProtection = lockedAs true {
|
||||||
|
Cryptomining = true;
|
||||||
|
EmailTracking = true;
|
||||||
|
Fingerprinting = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
UserMessaging = locked {
|
||||||
|
ExtensionRecommendations = false;
|
||||||
|
FeatureRecommendations = false;
|
||||||
|
FirefoxLabs = false;
|
||||||
|
MoreFromMozilla = false;
|
||||||
|
SkipOnboarding = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
FirefoxSuggest = locked {
|
||||||
|
ImproveSuggest = false;
|
||||||
|
SponsoredSuggestions = false;
|
||||||
|
WebSuggestions = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
SearchEngines = {
|
||||||
|
Default = "Kagi";
|
||||||
|
|
||||||
|
PreventInstalls = true;
|
||||||
|
|
||||||
|
Remove = [
|
||||||
|
"Google"
|
||||||
|
"Bing"
|
||||||
|
"DuckDuckGo"
|
||||||
|
"Wikipedia (en)"
|
||||||
|
];
|
||||||
|
|
||||||
|
Add = [
|
||||||
|
{ Name = "Kagi"; Alias = "kk"; Method = "GET"; URLTemplate = "https://kagi.com/search?q={searchTerms}"; SuggestURLTemplate = "https://kagi.com/api/autosuggest?q={searchTerms}"; }
|
||||||
|
{ Name = "Google"; Alias = "gg"; Method = "GET"; URLTemplate = "https://google.com/search?q={searchTerms}"; SuggestURLTemplate = "https://google.com/complete/search?client=firefox&q={searchTerms}"; }
|
||||||
|
{ Name = "Yandex"; Alias = "yy"; Method = "GET"; URLTemplate = "https://yandex.com/search?text={searchTerms}"; SuggestURLTemplate = "https://suggest.yandex.com/suggest-ff.cgi?part={searchTerms}"; }
|
||||||
|
|
||||||
|
{ Name = "Wikipedia"; Alias = "ww"; Method = "GET"; URLTemplate = "https://en.wikipedia.org/w/index.php?title=Special:Search&search={searchTerms}"; }
|
||||||
|
{ Name = "YouTube"; Alias = "yt"; Method = "GET"; URLTemplate = "https://youtube.com/results?search_query={searchTerms}"; }
|
||||||
|
|
||||||
|
{ Name = "Sourcegraph"; Alias = "sg"; Method = "GET"; URLTemplate = "https://sourcegraph.com/search?q=context:global+{searchTerms}"; }
|
||||||
|
{ Name = "GitHub"; Alias = "gh"; Method = "GET"; URLTemplate = "https://github.com/search?type=repositories&q={searchTerms}"; }
|
||||||
|
{ Name = "Lib.rs"; Alias = "rs"; Method = "GET"; URLTemplate = "https://lib.rs/search?q={searchTerms}"; }
|
||||||
|
|
||||||
|
{ Name = "Seachix"; Alias = "sx"; Method = "GET"; URLTemplate = "https://searchix.ovh/?query={searchTerms}"; }
|
||||||
|
{ Name = "NixOS Packages"; Alias = "np"; Method = "GET"; URLTemplate = "https://search.nixos.org/packages?channel=unstable&sort=relevance&type=packages&query={searchTerms}"; }
|
||||||
|
{ Name = "NixOS Options"; Alias = "no"; Method = "GET"; URLTemplate = "https://search.nixos.org/options?channel=unstable&sort=relevance&type=options&query={searchTerms}"; }
|
||||||
|
{ Name = "Home Manager Options"; Alias = "ho"; Method = "GET"; URLTemplate = "https://home-manager-options.extranix.com/?release=master&query={searchTerms}"; }
|
||||||
|
{ Name = "Nix Darwin Options"; Alias = "do"; Method = "GET"; URLTemplate = "https://options.nix-darwin.uz/?release=master&query={searchTerms}"; }
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
in {
|
in {
|
||||||
home-manager.sharedModules = [{
|
home-manager.sharedModules = [{
|
||||||
programs.zen-browser = enabled {
|
programs.zen-browser = enabled {
|
||||||
# package = mkIf config.isDarwin null;
|
inherit policies;
|
||||||
|
|
||||||
policies = {
|
|
||||||
AutofillAddressEnabled = false;
|
|
||||||
AutofillCreditCardEnabled = false;
|
|
||||||
|
|
||||||
DisableAppUpdate = true;
|
|
||||||
DisableFeedbackCommands = true;
|
|
||||||
DisableFirefoxStudies = true;
|
|
||||||
DisablePocket = true;
|
|
||||||
DisableTelemetry = true;
|
|
||||||
|
|
||||||
# We want Zen to be the default browser.
|
|
||||||
DontCheckDefaultBrowser = false;
|
|
||||||
|
|
||||||
NoDefaultBookmarks = true;
|
|
||||||
|
|
||||||
# I accept the terms of use.
|
|
||||||
SkipTermsOfUse = true;
|
|
||||||
|
|
||||||
PictureInPicture = lockedAs false;
|
|
||||||
|
|
||||||
Homepage.StartPage = "previous-session";
|
|
||||||
|
|
||||||
EnableTrackingProtection = lockedAs true {
|
|
||||||
Cryptomining = true;
|
|
||||||
EmailTracking = true;
|
|
||||||
Fingerprinting = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
UserMessaging = locked {
|
|
||||||
ExtensionRecommendations = false;
|
|
||||||
FeatureRecommendations = false;
|
|
||||||
FirefoxLabs = false;
|
|
||||||
MoreFromMozilla = false;
|
|
||||||
SkipOnboarding = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
FirefoxSuggest = locked {
|
|
||||||
ImproveSuggest = false;
|
|
||||||
SponsoredSuggestions = false;
|
|
||||||
WebSuggestions = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# policies.Preferences = {
|
|
||||||
|
|
||||||
# };
|
|
||||||
};
|
};
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
|
@ -139,7 +139,7 @@ in merge <| mkIf config.isDesktop {
|
||||||
|
|
||||||
"SUPER+SHIFT, RETURN, exec, kitty"
|
"SUPER+SHIFT, RETURN, exec, kitty"
|
||||||
"SUPER , RETURN, exec, ghostty --gtk-single-instance=true"
|
"SUPER , RETURN, exec, ghostty --gtk-single-instance=true"
|
||||||
"SUPER , W , exec, zen-beta"
|
"SUPER , W , exec, zen"
|
||||||
"SUPER , D , exec, discord"
|
"SUPER , D , exec, discord"
|
||||||
"SUPER , Z , exec, zulip"
|
"SUPER , Z , exec, zulip"
|
||||||
"SUPER , M , exec, thunderbird"
|
"SUPER , M , exec, thunderbird"
|
||||||
|
|
|
@ -35,9 +35,9 @@ in merge <| mkIf config.isDesktop {
|
||||||
"hyprland/window" = {
|
"hyprland/window" = {
|
||||||
separate-outputs = true;
|
separate-outputs = true;
|
||||||
|
|
||||||
rewrite."(.*) - Discord" = " $1";
|
rewrite."(.*) - Discord" = " $1";
|
||||||
rewrite."(.*) — Zen" = " $1";
|
rewrite."(.*) — Zen" = " $1";
|
||||||
rewrite."(.*) — nu" = " $1";
|
rewrite."(.*) — nu" = " $1";
|
||||||
};
|
};
|
||||||
|
|
||||||
modules-right = [ "tray" "pulseaudio" "backlight" "cpu" "memory" "network" "battery" "clock" ];
|
modules-right = [ "tray" "pulseaudio" "backlight" "cpu" "memory" "network" "battery" "clock" ];
|
||||||
|
|
|
@ -55,9 +55,8 @@ def main --wrapped [
|
||||||
] | append ($args_split | get 0 | where { $in != "" })
|
] | append ($args_split | get 0 | where { $in != "" })
|
||||||
|
|
||||||
let nix_flags = [
|
let nix_flags = [
|
||||||
"--option" "accept-flake-config" "true"
|
"--accept-flake-config"
|
||||||
# "--option" "eval-cache" "false"
|
"--extra-experimental-features" "pipe-operators"
|
||||||
"--option" "extra-experimental-features" "pipe-operators"
|
|
||||||
] | append ($args_split | get --ignore-errors 1 | default [])
|
] | append ($args_split | get --ignore-errors 1 | default [])
|
||||||
|
|
||||||
if (uname | get kernel-name) == "Darwin" {
|
if (uname | get kernel-name) == "Darwin" {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue