[HowTo] Create a Desktop Shortcut KDE Service Menu

This service menu is designed as a tool to effortlessly create one or more shortcuts from the file manager, using a symbolic link generated with a quick right mouse click. My user case is that I tend to send multiple work-in-progress files to my desktop simultaneously, and this satisfies my needs.

The ServiceMenu will be created in ~/.local/share/kservices5/ServiceMenus/

If that path doesn’t exist for your user, create it with:

mkdir -p ~/.local/share/kservices5/ServiceMenus

Create createdesktopshortcut.desktop with kate:

kate ~/.local/share/kservices5/ServiceMenus/createdesktopshortcut.desktop

Add the lines:

[Desktop Entry]

[Desktop Action sendDesktop]
Name=Create desktop shortcut
Name[de]=Desktopverknüpfung erstellen
Name[fr]=Créer un raccourci sur le bureau
Name[es]=Crear acceso directo del escritorio
Name[hr_HR]=Asztali parancsikon létrehozása
Name[nl]=Snelkoppeling op het bureaublad maken
Name[da]=Opret skrivebordsgenvej
Name[pt]=Criar atalho na área de trabalho
Name[nb]=Lag skrivebords snarvei
Name[pt_BR]=Criar atalho na área de trabalho
Name[ru_RU]=Создать ярлык на рабочем столе
Name[sr]=Napravi prečicu na desktopu
Exec=/bin/ln -s %F ~/Desktop

Please notice that you may need to run chmod to make sure it will work with your user.

chmod +x ~/.local/share/kservices5/ServiceMenus/createdesktopshortcut.desktop

That’s all.

PS. Feel free to correct me on translations. I used DeepL, but you never know, right?

Why? A .desktop file (if properly made) contains metadata to inform the desktop environment how to associate programs to file types, and execute the defined Exec but was never designed to execute itself.

Check my last how-to about a service menu for vlc.

A forum member complained about not being able to run the service menu unless he made it executable.