Compare commits

...

2 Commits

4 changed files with 98 additions and 29 deletions

View File

@ -61,6 +61,7 @@
"${username}@${hostname}" = home-manager.lib.homeManagerConfiguration { "${username}@${hostname}" = home-manager.lib.homeManagerConfiguration {
pkgs = import nixpkgs { pkgs = import nixpkgs {
system = "x86_64-linux"; system = "x86_64-linux";
config.allowUnfree = true;
overlays = [ nur.overlay ]; overlays = [ nur.overlay ];
}; };
extraSpecialArgs = { inherit inputs; }; extraSpecialArgs = { inherit inputs; };

View File

@ -94,5 +94,9 @@
sessionVariables = { sessionVariables = {
ANI_CLI_PLAYER = "mpv"; ANI_CLI_PLAYER = "mpv";
}; };
file = {
".config/nixpkgs/config.nix".text = "{ allowUnfree = true; }";
};
}; };
} }

View File

@ -1,4 +1,4 @@
{ pkgs, ... }: { lib, pkgs, ... }:
{ {
programs.firefox = { programs.firefox = {
enable = true; enable = true;
@ -19,52 +19,121 @@
}; };
}; };
extensions = with pkgs.nur.repos.rycee.firefox-addons; [
ublock-origin
private-relay
libredirect
reddit-enhancement-suite
enhancer-for-youtube
qr-code-address-bar
];
settings = {
"browser.newtabpage.pinned" = [
{
label = "Arch Wiki";
url = "https://wiki.archlinux.org";
}
{
label = "Translate";
url = "https://mozhi.pussthecat.org";
}
{
label = "ChatGPT";
url = "https://chatgpt.com";
}
{
label = "YouTube";
url = "https://youtube.com";
}
{
label = "Reddit";
url = "https://old.reddit.com";
}
{
label = "4chan";
url = "https://www.4chan.org/frames";
}
];
"browser.aboutConfig.showWarning" = false;
"browser.translations.automaticallyPopup" = false;
"browser.tabs.inTitlebar" = 0;
"services.sync.engine.addons" = false;
"services.sync.username" = "xezo360hye@gmail.com";
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
"extensions.autoDisableScopes" = 0;
};
search = { search = {
force = true; force = true;
default = "DuckDuckGo"; default = "DuckDuckGo";
engines = {
engines = let
makeShortcuts = let
prefix = "@";
in map (shortcut: prefix + shortcut);
hideEngines = let
hideEngine = engine: {
name = engine;
value = {
metaData.hidden = true;
};
};
in engines: lib.listToAttrs (map hideEngine engines);
in (hideEngines [ "Google" "Bing" "Amazon.com" "eBay" ]) //
{
"Arch Wiki" = {
urls = [{ template = "https://wiki.archlinux.org/index.php?search={searchTerms}"; }];
iconUpdateURL = "https://wiki.archlinux.org/favicon.ico";
definedAliases = makeShortcuts [ "archlinux" "aw" ];
};
"Nix Packages" = { "Nix Packages" = {
urls = [{ urls = [{
template = "https://search.nixos.org/packages"; template = "https://search.nixos.org/packages";
params = [ params = [
{ name = "type"; value = "packages"; } { name = "type"; value = "packages"; }
{ name = "channel"; value = "unstable"; }
{ name = "query"; value = "{searchTerms}"; } { name = "query"; value = "{searchTerms}"; }
]; ];
}]; }];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg"; icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = [ "@np" ]; definedAliases = makeShortcuts [ "nixpkgs" "packages" "np" ];
}; };
"NixOS Wiki" = { "NixOS Wiki" = {
urls = [{ template = "https://wiki.nixos.org/index.php?search={searchTerms}"; }]; urls = [{ template = "https://wiki.nixos.org/w/index.php?search={searchTerms}"; }];
iconUpdateURL = "https://wiki.nixos.org/favicon.png"; iconUpdateURL = "https://wiki.nixos.org/favicon.png";
updateInterval = 24 * 60 * 60 * 1000; definedAliases = makeShortcuts [ "nixos" "nw" ];
definedAliases = [ "@nw" ];
}; };
"MyNixOS" = { "MyNixOS" = {
urls = [{ template = "https://mynixos.com/search?q={searchTerms}"; }]; urls = [{ template = "https://mynixos.com/search?q={searchTerms}"; }];
iconUpdateURL = "https://mynixos.com/favicon-light.svg"; iconUpdateURL = "https://mynixos.com/favicon-light.svg";
definedAliases = [ "@mn" "@mw" ]; definedAliases = makeShortcuts [ "mynixos" "mw" ];
}; };
"Bing".metaData.hidden = true; "RuTracker" = {
"Google".metaData.hidden = true; urls = [{ template = "https://rutracker.org/forum/tracker.php?nm={searchTerms}"; }];
"Amazon.com".metaData.hidden = true; iconUpdateURL = "https://rutracker.org/favicon.ico";
"eBay".metaData.hidden = true; definedAliases = makeShortcuts [ "rutracker" "rt" ];
};
}; };
}; };
}; };
policies = { policies = {
DontCheckDefaultBrowser = true;
DisableFirefoxStudies = true; DisableFirefoxStudies = true;
DisableTelemetry = true; DisableTelemetry = true;
DisablePocket = true; DisablePocket = true;
DontCheckDefaultBrowser = true;
DownloadDirectory = "\${home}";
EnableTrackingProtection = { EnableTrackingProtection = {
Value = true; Value = true;
Locked = false; Locked = false;
@ -78,20 +147,11 @@
FirefoxHome = { FirefoxHome = {
SponsoredTopSites = false; SponsoredTopSites = false;
Pocket = false;
SponsoredPocket = false; SponsoredPocket = false;
Pocket = false;
}; };
StartDownloadsInTempDirectory = true; StartDownloadsInTempDirectory = true;
TranslateEnabled = true;
Preferences = {
"browser.translations.automaticallyPopup" = {
Value = false;
Status = "default";
};
};
}; };
}; };
} }

View File

@ -1,6 +1,9 @@
{ pkgs, ... }: { pkgs, ... }:
{ {
programs.firefox.profiles.default = { programs.firefox = {
nativeMessagingHosts = [ pkgs.plasma-browser-integration ];
profiles.default = {
extensions = [ pkgs.nur.repos.rycee.firefox-addons.plasma-integration ]; extensions = [ pkgs.nur.repos.rycee.firefox-addons.plasma-integration ];
settings = { settings = {
@ -8,6 +11,7 @@
"media.hardwaremediakeys.enabled" = false; "media.hardwaremediakeys.enabled" = false;
}; };
}; };
};
programs.plasma = { programs.plasma = {
enable = true; enable = true;