https://bugs.kde.org/show_bug.cgi?id=475056
Bug ID: 475056 Summary: Deleting and recreating a command keyboard shortcut generates a new .desktop file every time Classification: Frameworks and Libraries Product: frameworks-kglobalaccel Version: unspecified Platform: Other OS: Linux Status: REPORTED Severity: normal Priority: NOR Component: general Assignee: kdelibs-b...@kde.org Reporter: herzensch...@gmail.com Target Milestone: --- SUMMARY If you create a new keyboard shortcut that triggers a command, assign it a shortcut (so it appears in ~/.config/kglobalshortcutsrc), delete it, and recreate it, it generates a new .desktop file in ~/.local/share/applications following the naming scheme executable{,-1,-2,-3,...,-n}.desktop. The curious thing is that the entries in ~/.config/kglobalshortcutsrc do disappear fine when you delete a shortcut, it's just the .desktop file that doesn't. So if the user keeps testing to figure whether a command works well or not, they might end up with several redundant .desktop files. STEPS TO REPRODUCE 1. Go to Shortcuts -> Add Command... 2. Create a new command /usr/bin/kdialog --msgbox "Sup" 3. Assign a shortcut to it, for example, Meta+K 4. Click Apply 5. Verify that ~/.config/kglobalshortcutsrc contains a kdialog entry, it should point to kdialog.desktop 6. Delete the shortcut via System Settings 7. Create a new one that also uses kdialog 8. Verify that ~/.config/kglobalshortcutsrc contains a kdialog entry, it should point to kdialog-2.desktop OBSERVED RESULT Every time you recreate the shortcut, a new desktop entry gets added to ~/.local/share/applications without removing the original. EXPECTED RESULT Every time you delete the shortcut, the original desktop entry gets deleted, and every time you create a new shortcut using the same executable, the new desktop entry reuses its name. -- You are receiving this mail because: You are watching all bug changes.