Ark right click extract commands

Hello,

I am on Tuxedo up to date, (plasma 6, wayland).
Before updating to Plasma 6, when right-clicking in Dolphin on an archive, there used to be four commands in the Extract submenu: Extract here (extracted the contents of the archive to the current folder), Extract here (autodetect subfolder) (extracted the contents of the archive in a subfolder named as the archive, if the archive did not contain a single folder containing all other contained files), Extract to (queried the user for the destination folder), and Extract here and delete archive.

After the update, the autodetect subfolder option is no longer present, and the Extract here option always creates a subfolder.

My question is: is there a way to have an extract command that does not create the subfolder?
I tried unchecking the “Preserve paths when extracting” option in Ark’s settings, but that had no effect.

Ideally, I would like to be able to create custom archiving and unarchiving commands and adding them to the right-click menu, like WinRAR does under Windows, but I suppose that is not really feasible.

There are many custom Dolphin context menu addons one can install, or even create.
There may already be ones that do what you want.

Should be fairly easy to do. A desktop file containing a bunch of ark commands and kdialogs.

An extract here ( single file) would be something like:

[Desktop Entry]
Name=Extract Here
Type=Service
ServiceTypes=KonqPopupMenu/Plugin
MimeType=application/x-deb;application/x-cd-image;application/x-bcpio;application/x-cpio;application/x-cpio-compressed;application/x-sv4cpio;application/x-sv4crc;application/x-rpm;application/x-compress;application/gzip;application/x-bzip;application/x-bzip2;application/x-lzma;application/x-xz;application/zlib;application/zstd;application/x-lz4;application/x-lzip;application/x-lrzip;application/x-lzop;application/x-source-rpm;application/vnd.debian.binary-package;application/vnd.ms-cab-compressed;application/vnd.android.package-archive;application/x-xar;application/x-iso9660-appimage;application/x-archive;application/x-tar;application/x-compressed-tar;application/x-bzip-compressed-tar;application/x-bzip2-compressed-tar;application/x-tarz;application/x-xz-compressed-tar;application/x-lzma-compressed-tar;application/x-lzip-compressed-tar;application/x-tzo;application/x-lrzip-compressed-tar;application/x-lz4-compressed-tar;application/x-zstd-compressed-tar;application/vnd.rar;application/x-7z-compressed;application/zip;application/x-java-archive;application/java-archive;application/x-lha;application/x-stuffit;application/x-arj;application/arj;
X-KDE-Priority=TopLevel
Actions=extract

[Desktop Action extract]
Name=Extract Here
Icon=archive-extract
Exec=ark -ba %u

If you want more, add a submenu and your actions.

Thank you for the suggestions.
I have found one addon that puts an Extract here command in the right-click menu, but it does exactly what the existing command does, i.e. it creates a subfolder.
Creating an addon is not really an option, as I am no programmer.

I shall keep looking for addons, maybe I find one, but some do not appear to work, they give some error message when I try to install them.

If you don’t want it to create a subfolder, make the command read ark -b %u instead of ark -ba %u

Where do I save this .desktop file I am creating?

nvm, I found it:
~/.local/share/kio/servicemenus/

I have one more question, if it is ok to ask here:
How do I add this newly created command to the Click and drag menu of Dolphin?
By default this menu contains the default Extract here command, the one that creates a subfolder.

No idea.
The thing is, you could easily make a submenu for that desktop file ( without the need for a drag 'n drop action).
One submenu would be “extract here” and the other one “extract to”. But that second one requires a kdialog --getexistingdirectory. And THAT bug is still not solved. At least, not on the latest plasma 5. Maybe it works on plasma 6, but it certainly doesn’t on 5 ( despite the claim it was solved). That particular kdialog still opens a kdialog --getsavefilename. So, to simply extract each separate file from a compressed one and putting those in a directory of choice without creating a folder…I have no idea