Open midirhee12 opened 1 year ago
Hmm, there's not really a good way of working around this since both will use the same file for configuring search engines, and Firefox doesn't offer some kind of config layering for search engines.
Most of the time in home manager you loose out on imperative configuration if you opt for a declarative configuration. I'd recommend porting those extension search engines to the declarative configuration if you want both.
I'll also try to see if there's some way we can merge the config from extensions defined in programs.firefox.profiles.<name>.extensions
, but that would likely require IFDs.
Okay, I'm actually finding some seemingly non-deterministic behavior. I somehow managed to get some search extensions to work after a few restarts of firefox and running home-manager a few more times. I'm trying to investigate further, but I'm really clueless as to why.
I think I should also note that I'm using search.force
for my configuration.
I'm wondering if this is a problem with how firefox determines what search engines it has instead of an actual home-manager issue.
Oh, so sometimes Firefox will override the file and that can occur between home-manager activations, but the next time home-manager is activated, it will be reverted to the declarative configuration.
I don't think it's much of "reverting" per se. When the seach extensions do finally start working, the declarative configurations of the search engine still work as well. It's some how reading from both.
Note: I have no experience with imperatively installing search extensions. These are extensions installed from home-manager itself.
Oh, but that would still make sense. Firefox would imperatively merge the configuration generated by home-manager with the extension configuration.
So when Firefox overrides the configuration, it would keep the declarative options, but when home-manager gets activated it would revert back to the declarative configuration.
Yes, but, if I remember correctly, what also happens is that home-manager stops being able to manage firefox after firefox makes imperative changes such as installing extensions on its own.
If you're using the force
option for the search engines then home-manager is going to forcibly replace the file rather than complain about the file already existing.
I feel like this is all pretty confusing because of the way Firefox handles search configuration. In your case the extensions are installed declaratively, but Firefox imports the search configuration from those extensions imperatively 🫠
Okay, new update. Some of the one's I've set are getting removed randomly, ie - wikipedia (en) set to alias "w" just got removed today.
Thank you for your contribution! I marked this issue as stale due to inactivity. Please be considerate of people watching this issue and receiving notifications before commenting 'I have this issue too'. We welcome additional information that will help resolve this issue. Please read the relevant sections below before commenting.
* If this is resolved, please consider closing it so that the maintainers know not to focus on this. * If this might still be an issue, but you are not interested in promoting its resolution, please consider closing it while encouraging others to take over and reopen an issue if they care enough. * If you know how to solve the issue, please consider submitting a Pull Request that addresses this issue.
* If you are also experiencing this issue, please add details of your situation to help with the debugging process. * If you know how to solve the issue, please consider submitting a Pull Request that addresses this issue.
Don't be afraid to manually close an issue, even if it holds valuable information. Closed issues stay in the system for people to search, read, cross-reference, or even reopen – nothing is lost! Closing obsolete issues is an important way to help maintainers focus their time and effort.
Are you following the right branch?
Is there an existing issue for this?
Issue description
Steps to Reproduce
programs.firefox.profiles.<name>.search.engines
options.programs.firefox.profiles.<name>.extensions
).Note: this still breaks even if you installed the search engine extensions through home-manager using ``
Actual behavior
Only the search engines defined using the
programs.firefox.profiles.<name>.search.engines
options work correctly.Expected behavior
Both the search engines installed via extensions and the home-manager option should work as normal.
Maintainer CC
@kira-bruneau
System information