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

Add an option to display full path of executable #1154

Open
2 tasks done
brunetton opened this issue Nov 16, 2022 · 8 comments
Open
2 tasks done

Add an option to display full path of executable #1154

brunetton opened this issue Nov 16, 2022 · 8 comments
Labels
feature Completely new feature

Comments

@brunetton
Copy link

Description

Hi dear devs of this life-saver Ulauncher !
I really hope I'm not doing any duplicate here.

The problem

I'm using Ubuntu and Ubuntu is using snap; and I often mix snap versions and Ubuntu version of softwares, like Josm in this example.

Capture d’écran du 2022-11-16 14-21-39

Here it's impossible to say "who is Debian package (should start with /usr/bin) and who is snap version (should start with /snap)

Proposed solution

I'd love to be able to activate an option to display full path of executables below the program name. Something like:

t

Hope this is clear and concise.
Thanks

Communication guidelines

  • I have read and agree with Ulauncher's communication guidelines and checked the existing feature requests before suggesting this.

Feature isn't possible to support as an extension.

  • This feature request cannot satisfactory be supported as a third party extension.
@brunetton brunetton added the feature Completely new feature label Nov 16, 2022
@friday
Copy link
Member

friday commented Nov 16, 2022

Thanks for the feedback and suggestion.

I don't think this is something I want added to Ulauncher, because it's an uncommon use case and not something the launcher need to handle.

If you need to distinguish two versions of the same app you can copy one of the desktop entries for one of them to ~/.local/share/applications and change the name and/or icon in it there.

For example, copy /usr/share/applications/ulauncher.desktop to ~/.local/share/applications/ulauncher.desktop and edit the new file to set the "name" to something different, and this renames Ulauncher for all apps that handle desktop entries.

@friday
Copy link
Member

friday commented Nov 16, 2022

I think if anything, we should allow a more powerful advanced override of desktop entries, like saying "Always hide/show/rename x.desktop" or if the binary path starts/ends with something. This is something I considered before, but think the value of is not very high.

Additionally we could try to detect flatpaks/snaps and try to highlight them differently perhaps, but I don't know if that can be done safely, or how, and it's not a priority.

@brunetton
Copy link
Author

If you need to distinguish two versions of the same app you can copy one of the desktop entries for one of them to ~/.local/share/applications and change the name and/or icon in it there.

For example, copy /usr/share/applications/ulauncher.desktop to ~/.local/share/applications/ulauncher.desktop and edit the new file to set the "name" to something different, and this renames Ulauncher for all apps that handle desktop entries.

Thanks a lot for your reply. This is a quite "complicated" workaround, quite long and not very satisfying.

Would you be open to a pull request if I take some time to add this feature ? (not enabled by default, but activable in preferences) ?

@friday
Copy link
Member

friday commented Nov 16, 2022

It's not a complicated workaround. It takes a few seconds and can be scripted. I have been using this workaround for years for fixing other things. If you have duplicate applications that's very unusual and on you to fix. Not the launcher app. Although as mentioned I might be in favor of highlighting flatpaks and snaps if it can be done in a reliable way and it's helpful to others.

I'll leave the issue open so people can vote or comment if they agree, but I really don't want settings for every niche use-cases like this in Ulauncher. Then we'd have to remember to test this every time we change the UI for example, and the list of settings grow longer and more complicated for people looking for other settings. See: https://www.youtube.com/watch?v=glZ1C-Yu5tw

@brunetton
Copy link
Author

I'll leave the issue open so people can vote or comment if they agree, but I really don't want settings for every niche use-cases like this in Ulauncher. Then we'd have to remember to test this every time we change the UI for example, and the list of settings grow longer and more complicated for people looking for other settings. See: https://www.youtube.com/watch?v=glZ1C-Yu5tw

Thanks. Indeed, I can totally understand this point :)
Thanks again for your time anyway

@hsandt
Copy link

hsandt commented May 14, 2023

I got another use case: I'm about to install an app but notice an older version already exists. I want to remove the old version. There is no way to list all the AppImages on my drive. But I know it generates .desktop files (this is how I spot the old version in the first place), and I want to find the .desktop which contains the target location to the binary.

But it would be even faster if I could directly see the target location and go there (e.g. by right-clicking on the app when it's shown).

Currently, finding the location of a specific .desktop file visible in launcher requires manual steps:
https://askubuntu.com/questions/1467900/how-to-find-the-location-of-a-specific-desktop-file-visible-in-launcher
and you must still open it to get the application path at the end. Seeing it directly in the launcher would help a lot. A right-click or shortcut to copy/open location path even more.

I must admit I downloaded Ulauncher specifically because native Dash/Panel doesn't do it and I think I saw some subtitles in the Ulauncher demo GIF under the app name, and thought that maybe it could be customized to show a path instead of a description. Then I noticed it wasn't, and found this issue!

@brunetton
Copy link
Author

I got another use case: I'm about to install an app but notice an older version already exists. I want to remove the old version. There is no way to list all the AppImages on my drive. But I know it generates .desktop files (this is how I spot the old version in the first place), and I want to find the .desktop which contains the target location to the binary.

But it would be even faster if I could directly see the target location and go there (e.g. by right-clicking on the app when it's shown).

Currently, finding the location of a specific .desktop file visible in launcher requires manual steps: https://askubuntu.com/questions/1467900/how-to-find-the-location-of-a-specific-desktop-file-visible-in-launcher and you must still open it to get the application path at the end. Seeing it directly in the launcher would help a lot. A right-click or shortcut to copy/open location path even more.

I must admit I downloaded Ulauncher specifically because native Dash/Panel doesn't do it and I think I saw some subtitles in the Ulauncher demo GIF under the app name, and thought that maybe it could be customized to show a path instead of a description. Then I noticed it wasn't, and found this issue!

As a workaround I personally use a script I've made to show executable path of a desktop app (it must have a window):

  • install Custom scripts extension
  • edit the scripts file and add this script:
     {
         "name": "Copy process command",
         "description": "Click onto process to copy command",
         "icon": null,
         "script": "id=`xprop _NET_WM_PID | awk '/PID/ {print $3}'`; cat /proc/$id/cmdline | xargs -0 | xclip -selection clipboard"
     },

This is not a perfect workaround but it can help identifying binary paths.

@brunetton
Copy link
Author

Finally I took some time and created a working fork for this; available here: https://github.com/brunetton/Ulauncher

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

No branches or pull requests

3 participants