在 Deepin Linux 上测试 go-appimage

Testing go-appimage on Deepin Linux

go-appimage is an experimental implementation of AppImage tools in Go. It is not ready for production yet, but is available for testing and development.

This document describes how to test it on Deepin Linux. It also describes areas that are not working correctly in Deepin Linux yet and for which help is greatly appreciated.

For any questions/bugs, please post here or write to probono@puredarwin.org (Chinese or English).

Boot Deepin Linux Live ISO

  1. Download the Deepin Linux Live ISO 15.11 from https://www.deepin.org/de/download/

  2. Flash it to a USB drive using Deepin Boot Maker or balenaEtcher

  3. Boot your computer from the USB drive

  4. In the bootloader screen, press the Tab key to edit the Linux boot command line

  5. Delete the livecd-installer part. You can also change the language if you want. It should read: BOOT_IMAGE=/live/vmlinuz boot=live components quiet splash union=overlay locales=en_US.UTF-8 initrd=/live/initrd.lz

  6. Press Enter to boot. The system will boot into the Deepin Linux desktop (not the installer)

Download and run the AppImage daemon

  1. Download the appimaged-*-x86_64.AppImage from https://github.com/probonopd/go-appimage/releases/tag/continuous
  2. Double-click the downloaded appimaged-*-x86_64.AppImage
  3. Click “Run”

Use the AppImage daemon

Basic operation

The AppImage daemon monitors common directories on the system, including ~/Downloads and ~/Applications for new AppImages and will integrate AppImages into the system (e.g., put it into the Launcher menu).

  1. Download any AppImage, e.g., qpdf-*-x86_64.AppImage from https://github.com/qpdf/qpdf/releases
  2. Click “Save” in the dialog box and save in ~/Downloads or ~/Applications
  3. Click the Deepin Launcher button
  4. Type “pdf”
  5. qpdf will show up as an installed application, you can launch it by clicking on it
    ![](https://user-images.githubusercontent.com/2480569/69624397-842f5c80-103c-11ea-9b7b-6db2d2724693.png
  6. (Note that qpdf is a command line tool that requires an argument - hence we see an error message that would normally be printed only to stderr)

Desktop notifications for updates

When a new version of an AppImage that uses this functionality is published, the AppImage daemon shows a desktop notification informing the user that an update is available.

Currently this works only for AppImages created on GitHub using appimagetool-*-x86_64.AppImage from https://github.com/probonopd/go-appimage/releases/tag/continuous).

Desktop notifications when AppImages cannot run

If a defective AppImage (e.g., missing libraries) is launched from the Launcher, a desktop notification is shown informing the user about the error. In this case, the user can ask the developer of the application to fix the AppImage.

Applications on external drives

The AppImage daemon allows for plug-and-play of applications that are stored on external USB storage drives.

  1. On another computer, create a folder /Applications in the root directory of an external USB storage medium (use NTFS because it does not work yet with FAT)
  2. Copy an AppImage into that directory
  3. Eject the external USB storage medium
  4. Attach the external USB storage medium to the Deepin Linux computer where the AppImage daemon is running
  5. Mount the external USB storage medium on Deepin Linux (click on it in the file manager)
  6. You should see a notification “Application added”
  7. The application should be in the Deepin Launcher
  8. Eject the external USB storage medium
  9. The application should no longer be in the Deepin Launcher

Not working in Deepin yet

The following is not working yet in Deepin Linux. It is working in other distributions. So any help is appreciated to make it work on Deepin, too.

Right-click in the Launcher

  1. Download AppImageUpdater-*-x86_64.AppImage from https://github.com/antony-jr/AppImageUpdater/releases/tag/continuous

  2. Click the Deepin Launcher button

  3. Type “pdf”

  4. qpdf will show up

  5. Click the qpdf icon with the right mouse button

  6. A menu will appear. There should be “Update” but there is not. How can this be fixed? (It does work e.g., in KDE and GNOME but not in Deepin yet.) For comparison, this is how it looks on GNOME:

Thumbnails

  1. In the file manager, go to ~/Downloads or ~/Applications (where you had downloaded the AppImages before)

  2. The applications should have application icons, but they do not have the correct icons. For comparison, this is how it looks on Xfce:

  3. Go to ~/.cache/thumbnails/normal in the file manager. You should see thumbnail files that have been created by the AppImage daemon. Why is the Deepin Linux desktop not using them?

Launching applications on FAT

Due to an issue in UDisks, FAT partitions are automounted with the showexec option. This prevents any type of executable from running from FAT partitions, including AppImages. As a workaround, you can do (USE THIS AT YOUR OWN RISK):

sudo su
systemctl stop udisks2
sed -i -e 's|showexec|\x00\x00\x00\x00\x00\x00\x00\x00|g' /usr/lib/udisks2/udisksd
systemctl restart udisks2

Possibly a patch could be considered in Deepin Linux to make this work properly.

Desktop notifications disappear too fast

Desktop notifications disappear too fast. When I set the timeout to 120000 milliseconds, I expect the notification to stay on the screen for 2 minutes. But it disappears after a couple of seconds on Deepin.

Newline character in desktop notifications

Desktop notifications seem not to honor the \n newline character. It does work in Xfce.