chrisjbillington / desktop-app

OS menu shortcuts, correct taskbar behaviour, and environment activation for Python GUI apps
BSD 2-Clause "Simplified" License
6 stars 5 forks source link

Symlink does not point to -gui entry point file #19

Open linuxrider opened 2 years ago

linuxrider commented 2 years ago

Thank you for making desktop-app available! I was trying to use desktop-app for a project which should be used on Windows and Linux. For this I first added the following to setup.cfg which worked on Windows:

[options.entry_points]
gui_scripts =
    package_name-gui = desktop_app:entry_point

However, on linux this did not work since desktop-app symlinked package_name-package_name (which is used in the desktop file) to package_name (which does not exist) instead of package_name-gui (which exists). Did I miss something? A workaround is to add two entry points.

[options.entry_points]
gui_scripts =
    package_name-gui = desktop_app:entry_point
    # workaround so it also works linux in addition to windows
    package_name = desktop_app:entry_point
chrisjbillington commented 2 years ago

Thanks for the kind words!

Your workaround is the intended way to use it, since the "gui-scripts" concept does not exist on Linux. So just keep doing that, there's no downside that I'm aware of.