gyunaev / birdtray

new mail system tray notification icon for Thunderbird
GNU General Public License v3.0
782 stars 59 forks source link

Provide capability to find `thunderbird` in `PATH` #593

Open eclairevoyant opened 1 month ago

eclairevoyant commented 1 month ago

Description

Birdtray hardcodes a default path /usr/bin/thunderbird which may not exist when using birdtray as packaged via nix. In particular it will not exist on NixOS. If we then try to configure birdtray to use the absolute path to the binary, when thunderbird updates, that path will no longer be valid (due to the design of nix), and the absolute path has to be updated again.

Currently if you just put thunderbird into the "Advanced" > "Thunderbird command line", it will try to open ~/thunderbird instead. If you set it to be empty, it will go back to the default (/usr/bin/thunderbird).

As mentioned in https://github.com/NixOS/nixpkgs/issues/291745#issuecomment-1966670697, it seems like our best bet is to allow looking for thunderbird on PATH rather than hardcoding a location.

Example

Set "Advanced" > "Thunderbird command line" in the settings to thunderbird (or set advanced/tbcmdline in birdtray-config.json to [ "thunderbird" ]).