Configuration files and scripts for adding "Extract here" and "Compress" desktop entries to KDE applications' context menus. file-roller
and zip
are used for extraction and compression, respectively.
-
Determine KDE services directories, e.g., with
kde4-config --path services
on KDE 4. For KDE 5, one of the directories is~/.local/share/kservices5/ServiceMenus
. -
Create sub-directory "ServiceMenus" in one of KDE's services directories, e.g., in
~/.local/share/kservices5/ServiceMenus
viamkdir ~/.kde/share/kde4/services/ServiceMenus
. -
Copy the
desktop
files and Python scripts in this repository to the createdServiceMenus
sub-directory. -
Restart KDE applications, which now should contain two context menu entries, i.e.,
Extract here
(for files with an archive MIME type) andCompress
(for arbitrary files and directories).
Note that the create_zip
Python script contained in this repository is used by the Compress
entry to create a ZIP archive. The script creates a ZIP archive that contains all files and/or folders passed to it.
Tested with krusader 2.6.0 on Linux Mint 19.1 with file-roller 3.28 and zip 3.0.