1. Here’s a KDE Plasma service menu (dolphin context menu action) for creating a valid CACHEDIR.TAG file in the selected folder. Useful for excluding things from being backed up! (e.g. via restic with the --exclude-caches option)

    [Desktop Entry]
    Type=Service
    MimeType=inode/directory
    Actions=create_cachedir_tag
    
    [Desktop Action create_cachedir_tag]
    Name=Create CACHEDIR.TAG
    Icon=breeze/actions/22/document-edit-encrypt
    Exec=echo "Signature: 8a477f597d28d172789f06886806bc55" > %u/CACHEDIR.TAG
    

    Put it somewhere like .local/share/kio/servicemenus/cachedir-tag.desktop, make it executable and it should show up in your context menu.

  2. Ended up getting frustrated with the old version of DigiKam available on Kubuntu, so tried installing an AppImage. The state of AppImage integration with Kubuntu is abysmal, and I open DigiKam fairly regularly, so I finally tried installing AppImageLauncher, which is recommended by DigiKam and is supposed to be a good tool for integrating AppImages with the desktop environment (something which Plasma should surely do itself, if AppImages are really going to be part of the future of linux app packaging).

    Unfortunately, installing AppImageLauncher completely broke my desktop environment, causing it to hang and preventing me from logging in. Looked it up and it was clearly related to whatever this issue is about, as moving .local/share/mime fixed it. Removing AppImageLauncher and the mime cache got things working again, and, lo, before it broke my system, AppImageLauncher had kindly made .desktop files for all my AppImages!

    At this point I decided to take a more manual approach to integrating AppImages I cared about with my DE, so I added a link from ~/Applications (where I store AppImages and other applications not installed via the package manager) to ~/.local/share/applications, where .desktop files are kept. Having quick access to this location makes manually managing .desktop files much more bearable, and I went about improving the ones AppImageLauncher had made (e.g. adding version numbers to the names – I find it very useful to know what version of an app I’m launching).

    So, back to DigiKam: at this point I had a DigiKam 8.3 AppImage installed and openable via launchers thanks to the .desktop file. It had to re-download the facial recognition files, but other than that picked up everything from before. However, in the main photo list view, the maximum size of the thumbnails was tiny.

    I spent some time poking around in settings and tweaking the QT scaling factor via the .desktop file, but I’ll spare you the details. tl;dr: if you want the DigiKam 8.3 AppImage to let you see large thumbnails on a high-DPI screen, you need to check the following boxes:

    • Miscellaneous → System → Use high DPI scaling from the screen factor
    • Vews → Icons → Use large thumbnail size for high screen resolution

    Restart DigiKam, and it should let you make thumbnails large enough to be useful. This is especially necessary seeing as how DigiKam’s photo list view has a horribly wasteful layout, with almost as much whitespace as photo surface area.

  3. If you’re in the unfortunate position of needing to use MuseScore4 on linux for some reason (for example to use its excellent MIDI to notation conversion) and are having issues with the Flatpak version having an unreadably tiny UI on high-DPI screens, here’s how to fix it.

    Open the .desktop file for MuseScore 4 – mine was in /var/lib/flatpak/app/org.musescore.MuseScore/current/active/export/share/applications/org.musescore.MuseScore.desktop

    Find the Exec key, and change the command to include --env=QT_SCALE_FACTOR=2. Mine ended up looking like this:

    Exec=/usr/bin/flatpak run --env=QT_SCALE_FACTOR=2 --branch=stable --arch=x86_64 --command=mscore --file-forwarding org.musescore.MuseScore @@ %F @@
    

    Save (you’ll need to enter your password, or to have launched the editor with sudo).

    Try launching MuseScore again. If you’re lucky, it’ll have a readable UI. If not, try restarting and launching it again — I haven’t found a way of successfully getting KDE to force-update all its .desktop files. Presumably there’s a cache somewhere? If anyone knows how to reliably do this, please let me know!

    This should work for any Flatpak which uses QT, on any desktop environment which uses .desktop files. I really hope “UI Scale” becomes a standard per-application setting in the near future.

    EDIT: thanks to carmanaught on the KDE forums for this additional suggestion to copy the .desktop file to ~/.local/share/applications rather than editing it in-place, and for details about how to set up a service to watch this folder and clear the desktop file cache whenever it’s edited.