Firefox: Difference between revisions

Klinger (talk | contribs)
Dander (talk | contribs)
capitalize firefox; don't use "you"; tidy up
Line 1: Line 1:
<translate>
<translate>
<!--T:1-->
<!--T:1-->
[https://www.mozilla.org/firefox Firefox] is a graphical web browser developed by Mozilla. It can be used with a [[Firefox Sync Server]].
[https://www.mozilla.org/firefox Firefox] is a graphical web browser developed by Mozilla.
</translate>
</translate>
<translate>
<translate>
Line 30: Line 30:
</translate>
</translate>
<translate>
<translate>
=== Variant: ESR === <!--T:9-->
=== Variant: Extended Support Release (ESR) === <!--T:9-->
</translate>
</translate>
<translate>
<translate>
<!--T:10-->
<!--T:10-->
<code>firefox-esr</code> is the '''E'''xtended '''S'''upport '''R'''elease of Firefox provided by Mozilla, which receives only security updates and a more relaxed cadence of feature implementation.
<code>firefox-esr</code> is a variant of Firefox provided by Mozilla, which receives security updates for a longer period of time and a more relaxed cadence of feature implementation. It also allows users to change otherwise untouchable behavior with Firefox using policies.
</translate>
</translate>
<translate>
<translate>
Line 44: Line 44:
</translate>
</translate>
<translate>
<translate>
==== Reproducible ==== <!--T:13-->
==== Method #1: Using nix-community/flake-firefox-nightly ==== <!--T:13-->
</translate>
</translate>
<translate>
<translate>
<!--T:14-->
<!--T:14-->
This method uses flakes to pull in nightly versions of Firefox in a reproducible way, and is recommended for use. If you don't want to use flakes, check out the next section.
This method is reproducible but may lag behind the upstream version of Firefox Nightly. It uses flakes.  


<!--T:15-->
<!--T:15-->
Line 71: Line 71:
}
}
</syntaxhighlight>
</syntaxhighlight>
<translate>
==== Method #2: Using mozilla/nixpkgs-mozilla ==== <!--T:18-->
<!--T:17-->
<nowiki></translate></nowiki>
The downside of using this method is that you'll have to update the flake input before you can get a new nightly version, which also means that you might miss new builds since the flake lags behind the nightly release.
</translate>
<translate>
==== Non-reproducible (Impure) ==== <!--T:18-->
</translate>
<translate>
<translate>
<!--T:19-->
<!--T:19-->
Using this method is bad for reproducibility since it fetches resources from non-pinned URLs, but it also means you always get the latest nightly version when you build your system.
This method is not necessarily reproducible without a [[Flake]]-like system because it fetches resources from non-pinned URLs, but it will always be the latest Nightly  version.
</translate>
<translate>
<!--T:20-->
{{tip|1=If you don't want to use flakes but you still want to reproducibly install Firefox nightly, you might want to use this method with [https://github.com/nmattia/niv niv].}}
</translate>
<translate>
<!--T:21-->
<syntaxhighlight lang="nix">
<syntaxhighlight lang="nix">
nixpkgs.overlays =
nixpkgs.overlays =
Line 103: Line 91:
<translate>
<translate>
<!--T:22-->
<!--T:22-->
Once you've added the overlay, you'll need to pass the <code>--impure</code> option to nix commands. For example, in order to build and activate your configuration, you'll have to run:
It is also needed to pass the <code>--impure</code> option to nix commands. For example,
</translate>
</translate>
<syntaxHighlight lang="console">
<syntaxHighlight lang="console">
Line 212: Line 200:
</syntaxhighlight>
</syntaxhighlight>
<translate>
<translate>
== Troubleshooting== <!--T:36-->
== Troubleshooting==
</translate>
<translate>
=== If you can't start the browser because of a configuration error === <!--T:37-->
 
<!--T:38-->
For example:
</translate>
<syntaxhighlight lang="text">
firefox
1554035168269 Marionette FATAL XML parsing error: undefined entity
Location: chrome://browser/content/browser.xul
Line 2526, column 13:            <toolbarbutton id="tracking-protection-preferences-button"
JavaScript error: resource:///modules/aboutpages/AboutPrivateBrowsingHandler.jsm, line 28: TypeError: this.pageListener is undefined
</syntaxhighlight>
<translate>
<!--T:39-->
An easy way to get away from this is to start firefox with the <code>firefox -safe-mode</code> command. Then you can troubleshoot your actual problem or you can call your luck by calling the refresh option (a special button will appear when firefox starts in this mode). This will reset your configuration to a sane state and you will be usually able to start the browser again, but you will lose most of your customization.
</translate>
<translate>
=== <code>nativeMessagingHosts</code> doesn't work === <!--T:40-->
=== <code>nativeMessagingHosts</code> doesn't work === <!--T:40-->
</translate>
</translate>
<translate>
<translate>
<!--T:41-->
<!--T:41-->
Such as <code>enablePlasmaBrowserIntegration</code>, <code>enableGnomeExtensions</code>, and <code>enableBrowserpass</code>.
These options, for example  <code>enablePlasmaBrowserIntegration</code>, or<code>enableGnomeExtensions</code>, do not work with the <code>bin</code> variants of the Firefox packages or with Firefox installed via<code>nix-env</code>.
 
<!--T:42-->
They do not work with the <code>firefox-bin</code> derivation<ref>https://github.com/NixOS/nixpkgs/issues/47340#issuecomment-476368401</ref> or with <code>firefox</code> installed via <code>nix-env</code>
</translate>
</translate>
<hr />
<hr />
<references />
 
<translate>
<translate>
=== Screen Sharing under Wayland === <!--T:43-->
=== Screen Sharing under Wayland === <!--T:43-->
Line 250: Line 216:
When using Firefox with Wayland, screen sharing options might be limited and require additional configuration (exact capabilities vary with different compositors).
When using Firefox with Wayland, screen sharing options might be limited and require additional configuration (exact capabilities vary with different compositors).
</translate>
</translate>
<translate>
<!--T:47-->
* Enable [https://pipewire.org/ PipeWire]
</translate>
<syntaxhighlight lang="nix">
services.pipewire.enable = true;
</syntaxhighlight>
<translate>
<translate>
<!--T:45-->
<!--T:45-->
* add Pipewire support to Firefox:
* Add PipeWire support to Firefox:
</translate>
</translate>
<translate>
<translate>
<!--T:46-->
<!--T:46-->
<syntaxhighlight lang="nix">
<syntaxhighlight lang="nixos">
# when programs.firefox.enable == true
programs.firefox.enable = true
programs.firefox.wrapperConfig = {
programs.firefox.wrapperConfig = {
   pipewireSupport = true;
   pipewireSupport = true;
};
};
 
</syntaxhighlight>
<!--T:54-->
Alternatively, it is possible to override the Firefox derivation with [[PipeWire]] support to it:<syntaxhighlight lang="diff">
# or, alternatively
 
<!--T:55-->
environment.systemPackages = [
environment.systemPackages = [
  # Replace this
pkgs.firefox
  pkgs.firefox
pkgs.wrapFirefox (pkgs.firefox-unwrapped.override { pipewireSupport = true;}) {})
  # With this
  (pkgs.wrapFirefox (pkgs.firefox-unwrapped.override { pipewireSupport = true;}) {})
];
];
</syntaxhighlight>
</syntaxhighlight>
</translate>
</translate>
<translate>
<!--T:47-->
* Enable [https://pipewire.org/ PipeWire]
</translate>
<syntaxhighlight lang="nix">
services.pipewire.enable = true;
</syntaxhighlight>
<translate>
<translate>
<!--T:48-->
<!--T:48-->
Line 303: Line 267:
<!--T:50-->
<!--T:50-->
<syntaxhighlight lang="nix">
<syntaxhighlight lang="nix">
# Classical NixOS setup
# NixOS setup
environment.sessionVariables = {
environment.sessionVariables = {
   # only needed for Sway
   # only needed for Sway