I have revised my old instructions for creating a Dolphin service menu, as the old tutorial was intended for KDE 5. The new instructions below are intended for creating a Dolphin service menu with KDE Plasma 6.
Feel free to add any Dolphin service menus of your own to this thread.
Dolphin Root Service Menu Copy + for KDE 6:
Garuda includes a Dolphin service menu to easily create a duplicate/backup copy of a file via the Dolphin right click context menu.
Unfortunately, the Dolphin service menu that is included by default with the Garuda KDE editions cannot be used to backup root files.
The Dolphin service menu file I’ve created below provides an easy right click context menu option to create versioned backups of any root file you wish to duplicate.
This Dolphin service menu item will duplicate any root file you right click on and append a timestamp and a .bak
suffix to the files original name.
To enable this handy root backup method you simply need to create the required bak.desktop
file in the new location that KDE Plasma 6 utilizes for Dolphin Service Menus.
Instructions:
Create the required directory/subdirectory for the service menu file:
mkdir -p ~/.local/share/kio/servicemenus
To open the Kate text editor and create the required bak.desktop
file in the correct location, run in terminal:
kate -n /home/$USER/.local/share/kio/servicemenus/bak.desktop > /dev/null 2>&1 & disown
If you do not use the Kate text editor with KDE, then you can create the bak.desktop
file in the correct location with the following command:
touch /home/$USER/.local/share/kio/servicemenus/bak.desktop
In your preferred text editor, paste the following contents into your newly created bak.desktop
file:
[Desktop Entry]
Type=Service
ServiceTypes=KonqPopupMenu/Plugin
MimeType=all/all
Actions=bak;
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
Icon=application-x-trash
[Desktop Action bak]
Name=Backup here (Root)
Icon=application-x-trash
Exec=pkexec cp -rf %f %f"$(date -Iminutes)".bak
Save the above bak.desktop
file created using your text editor.
Then, make the desktop file executable:
chmod +x $HOME/.local/share/kio/servicemenus/bak.desktop
You may need to restart Dolphin for the service menu to become active, although I haven’t found this step necessary.
To create a timestamped backup copy simply right click on a root file in Dolphin and then select Backup here (root)
.
Usage example:
Right click on /etc/fstab
Click on Backup here (root)
Enter your password in the prompt window.
This will create a new timestamped backup copy such as:
/etc/fstab2025-01-05T04:35-08:00.bak
You may need to press F5 to refresh Dolphin’s view for the newly created timestamped backup file to become visible. Although it shows up immediately on my system once duplicated.