Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

An alternative way to set up Firefox and derivative browsers #578

Open
RetroViking opened this issue Nov 9, 2024 · 4 comments
Open

An alternative way to set up Firefox and derivative browsers #578

RetroViking opened this issue Nov 9, 2024 · 4 comments

Comments

@RetroViking
Copy link

RetroViking commented Nov 9, 2024

Compared to the current method of setting up Librewolf/Firefox, there is a simpler method which only requires adding a file to /etc/firefox/policies/ called policies.json. The following example installs addons and sets the desired default search engine. Users can then freely set whatever default search engine they want from within the browser itself, without worrying about the policies.json file. The file only activates if you are fresh-installing the browser or if you add something new to it (in which case, only the new addition will be applied).

{
    "policies": {
        "Extensions": {
            "Install": [
                "https://addons.mozilla.org/firefox/downloads/latest/desired-addon/latest.xpi",
                "https://addons.mozilla.org/firefox/downloads/latest/another-addon/latest.xpi"
            ]
        },
        "SearchEngines": {
            "Default": "NAME_OF_SEARCH_ENGINE"
        }
    }
}

If, for instance, the user decides to uninstall desired-addon, this choice is remembered despite desired-addon being in this list. And if the user does a completely fresh re-install of Firefox, all of the listed extensions will be auto-installed again. The only downside to this method is the message at the top of the Settings menu saying "your browser is being managed by your organization". If someone knows how to hide it please let me know.

Another alternative is the pull request by @aartoni . However, installing extensions the regular way via AMO, as above, could be more reliable long-term than using community-maintained AUR packages. The policies.json method is also compatible with multiple Firefox-type browsers.

@aartoni
Copy link
Contributor

aartoni commented Nov 10, 2024

Hello, I didn't know about this way of installing addons, clearly this is an improvement on what we have right now! As for the comparison with my PR, personally I like to have all my packages managed by a single package manager (i.e., yay). That would put less burden on the larbs.sh script because we can use the CSV we already have.

I understand your concern about community maintained AUR packages. They're sometimes overlooked or outdated, that's the case for librewolf-extension-istilldontcareaboutcookies-bin (I have already filed a request to orphan the package). However you should keep in mind that Arch packages from the main repositories should be promoted from the AUR to get there, the way it works is: when an AUR package receives enough votes it gets scheduled for inclusion in extra (world if you're on Artix). Hence, if the entire LARBS userbase votes for an AUR package it would be a matter of "when" the package will be merged not "if" it will. Of course we should address this issue and #510 before committing to massive voting.

I've looked around for a way of hiding the banner and couldn't find anything, but a banner that only appears in the settings menu isn't a big deal to me.

In the end I think this boils down to personal taste. Let's hear @LukeSmithxyz's opinion.

@RetroViking
Copy link
Author

RetroViking commented Nov 10, 2024

@aartoni , thanks for linking that issue. @appeasementPolitik , @LukeSmithxyz , to set the default search engine (and everything else that you want), you simply need to add/edit the /etc/firefox/policies/policies.json file. For convenience, a symlink to it can be added to $HOME/.config/firefox. Mozilla's policies template provides some documentation.

Perhaps Firefox could be made default? On my system, LARBS-installed Librewolf is up to 4-5 seconds slower than stock Firefox. No doubt using Arkenfox could contribute to this. As an alternative to Arkenfox, I suggest the (perhaps) saner Betterfox. The Fastfox part makes Firefox comparable in speed to a Chromium-based browser.

One other thing to note is that ublock origin already provides the functionality of istilldontcareaboutcookies. True, the user must go to Ublock's Settings -> Filter lists -> Cookie notices and tick the desired box(es), but installing an extra extension just because of that has its cons too. But if minimal manual setup is desired, then I guess a dedicated extension will do.

@aartoni
Copy link
Contributor

aartoni commented Nov 10, 2024

We're creeping out of the original scope of this issue, let's open another one for Betterfox and keep this on using the policies.json configuration. Same for adding/removing specific extensions.

@RetroViking RetroViking changed the title About automatically installing browser extensions An alternative way to set up Firefox and derivative browsers Nov 10, 2024
@RetroViking
Copy link
Author

Since the policies.json configuration can target most Firefox settings, I have changed the title accordingly. Treat my side remarks on ublock an user.js as a heads-up for anybody interested in doing a PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants