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

Desktop entries deduplication #19

Closed
friday opened this issue Sep 13, 2021 · 3 comments · Fixed by #27
Closed

Desktop entries deduplication #19

friday opened this issue Sep 13, 2021 · 3 comments · Fixed by #27

Comments

@friday
Copy link
Contributor

friday commented Sep 13, 2021

If multiple files have the same desktop file ID, the first one in the $XDG_DATA_DIRS precedence order is used.

Currently I have Nautilus duplicated in these two directories:

  • ~/.local/share/applications/org.gnome.Nautilus.desktop
  • /usr/share/applications/org.gnome.Nautilus.desktop

I do this to override something in the desktop entries and avoid rewriting it when I update the package it belongs to.

My xdg_data_dirs: ~/.local/share, /usr/local/share and /usr/share (XDG_DATA_DIRS is actually not set, but these are the paths that should be used when this is the case)

Screenshot from 2021-09-13 21-03-38

(same thing with "Bulk Rename", which is part of Thunar).

If you want this I could try to implement it, but I'm a Rust noob at best and haven't looked into your code.

@friday friday changed the title Desktop entries should be deduplicated Desktop entries deduplication Sep 13, 2021
@mmstick
Copy link
Member

mmstick commented Sep 13, 2021

There's currently a Set collection in the desktop-entries plugin that's filtering based on source and app ID. Removing the Hash and PartialEq condition for the src field would have it only consider the app ID. You would simply have to ensure that the local apps have a higher priority in the set than system apps.

@friday
Copy link
Contributor Author

friday commented Sep 13, 2021

Nice. Thank you for the pointers 👍

@friday
Copy link
Contributor Author

friday commented Oct 5, 2021

Awesome! Real life and other things got in between, so I never had the chance to start looking at it, but hope to be able to contribute soon :)

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

Successfully merging a pull request may close this issue.

2 participants