Following up on the same about chromium, I’m struggling to define command line defaults for the Brave browser:
Having
environment.systemPackages = with pkgs; [
(brave.override {
commandLineArgs = [
"--ozone-platform=no-such-thing" # on purpose to make it break
];
})
];
Does nothing at all - the resulting /run/current-system/sw/bin/brave script stays the same.
To my understanding, the override pattern is built-in in nixpkgs so I don’t understand what in Brave’s default.nix causes it being ignored (I’m on 22.05 stable channel of NixOS).
and the build indeed fails with ...brave/default.nix:1:1 called with unexpected argument 'foo', so my code is being included in the build but still no actual effect.
Nowadays you can just export NIXOS_OZONE_WL=1 in your login shell and all of the wrappers of Chromium-like applications (Chromium, Brave, Discord, Slack, etc.) will add the appropriate OZone flags.