mirror of
https://github.com/anotherhadi/nixy.git
synced 2026-04-02 11:12:09 +02:00
add brave settings
Signed-off-by: Hadi <112569860+anotherhadi@users.noreply.github.com>
This commit is contained in:
@@ -1,17 +1,70 @@
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
{pkgs, ...}: {
|
||||
programs.brave = {
|
||||
enable = true;
|
||||
commandLineArgs = [
|
||||
# Wayland Native
|
||||
"--enable-features=UseOzonePlatform"
|
||||
"--ozone-platform=wayland"
|
||||
|
||||
# Hardware Acceleration (NVIDIA optimized)
|
||||
"--enable-accelerated-video-decode"
|
||||
"--enable-gpu-rasterization"
|
||||
"--enable-zero-copy"
|
||||
"--ignore-gpu-blocklist"
|
||||
|
||||
# Performance
|
||||
"--enable-features=VaapiVideoDecoder"
|
||||
"--enable-features=VaapiVideoEncoder"
|
||||
"--enable-features=CanvasOopRasterization"
|
||||
"--disable-features=UseChromeOSDirectVideoDecoder"
|
||||
|
||||
# Privacy & Security
|
||||
"--disable-features=MediaRouter" # Disable Chromecast
|
||||
"--disable-features=OptimizationHints" # No Google suggestions
|
||||
"--disable-features=AutofillSavePaymentMethods"
|
||||
"--disable-background-networking" # No telemetry
|
||||
"--disable-sync" # Manual sync control
|
||||
|
||||
# Wayland-specific fixes
|
||||
"--disable-features=WaylandWpColorManagerV1" # Color management fix
|
||||
|
||||
# UI/UX
|
||||
"--force-dark-mode" # Match Stylix theme
|
||||
"--enable-features=WebUIDarkMode"
|
||||
"--no-default-browser-check"
|
||||
];
|
||||
extensions = let
|
||||
ids = [
|
||||
"cjpalhdlnbpafiamejdnhcphjbkeiagm" # ublock origin
|
||||
"dbepggeogbaibhgnhhndojpepiihcmeb" # vimium
|
||||
"eimadpbcbfnmbkopoojfekhnkhdbieeh" # dark reader
|
||||
"pkehgijcmpdhfbdbbnkijodmdjhbjlgp" # privacy badger
|
||||
"ghmbeldphafepmbegfdlkpapadhbakde" # proton pass
|
||||
"mmjbdbjnoablegbkcklggeknkfcjkjia" # custom new tab page
|
||||
];
|
||||
in
|
||||
map (id: {inherit id;}) ids;
|
||||
};
|
||||
|
||||
xdg.configFile."BraveSoftware/Brave-Browser/Policies/managed/policy.json".text = builtins.toJSON {
|
||||
BraveShieldsAdControl = 2;
|
||||
BraveShieldsTrackersBlocked = 1;
|
||||
BraveShieldsHttpsEverywhere = 1;
|
||||
BraveRewardsDisabled = 1;
|
||||
BraveWalletDisabled = 1;
|
||||
BraveVPNDisabled = 1;
|
||||
BraveAIChatEnabled = 0;
|
||||
PasswordManagerEnabled = 0;
|
||||
BravePlaylistEnabled = 0;
|
||||
BraveWebDiscoveryEnabled = 0;
|
||||
BraveStatsPingEnabled = 0;
|
||||
DnsOverHttpsMode = "automatic";
|
||||
BraveDarkMode = 1;
|
||||
};
|
||||
|
||||
home.sessionVariables = {
|
||||
DEFAULT_BROWSER = "${pkgs.brave}/bin/brave";
|
||||
BROWSER = "${pkgs.brave}/bin/brave";
|
||||
};
|
||||
|
||||
xdg.desktopEntries = {
|
||||
@@ -33,4 +86,27 @@
|
||||
categories = ["Network" "WebBrowser"];
|
||||
};
|
||||
};
|
||||
|
||||
# =================================================================
|
||||
# BRAVE SETTINGS (via brave://flags)
|
||||
# =================================================================
|
||||
|
||||
# These need to be set manually in brave://flags on first launch:
|
||||
# - Enable Tab Groups (UI)
|
||||
# - Enable Parallel Downloading
|
||||
# - Enable Reader Mode
|
||||
# - GPU Rasterization: Enabled
|
||||
# - Override software rendering list: Enabled
|
||||
#
|
||||
# Privacy settings (brave://settings/privacy):
|
||||
# - Block trackers & ads: Aggressive
|
||||
# - Block all fingerprinting
|
||||
# - Upgrade connections to HTTPS
|
||||
# - Block scripts: Off (breaks sites, use uBlock instead)
|
||||
# - Block cookies: Only 3rd party
|
||||
#
|
||||
# Appearance (brave://settings/appearance):
|
||||
# - Show home button: Off
|
||||
# - Show bookmarks bar: Only on new tab
|
||||
# - Use wide address bar: On
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user