A robust, per-user AppImage manager for Arch/Manjaro Linux that handles installation, extraction, and updates with a focus on idempotency and reliability.
This script lets you reliably install and manage AppImages without sudo, by extracting their contents and creating proper desktop entries that point to the extracted executables. This avoids common issues with AppImage runtimes and ensures consistent behavior across different systems.
AppImages are a convenient way to distribute applications, but they can have several drawbacks:
- Runtime Dependencies: Many AppImages rely on specific versions of FUSE (Filesystem in Userspace) which may not be installed or configured correctly on all systems. This often leads to the dreaded
dlopen()orfuseerrors. - Inconsistent Naming: Downloading different versions of the same AppImage (e.g.,
AppName-1.2.AppImage,AppName-1.3.AppImage) can lead to multiple, duplicate installations. - No Central Management: It's hard to track what AppImages are installed, where they are, and how to update them.
This script solves these problems by:
- Extracting First: Instead of running the AppImage directly, it extracts the contents. This completely bypasses the need for FUSE and avoids runtime dependency issues.
- Idempotent Installs: It uses the internal application name to identify apps, so installing a newer version will update the existing one instead of creating a duplicate.
- Robust Extraction: It uses a chain of fallback methods (including
binwalkand manual offset detection) to handle even the most stubborn or oddly-packaged AppImages. - Clean Integration: Creates standard desktop entries and icons for a seamless experience with your desktop environment (KDE, GNOME, etc.).
The script follows a robust, multi-step process for installation:
It first tries to extract the AppImage using the standard --appimage-extract command. If that fails, it uses a chain of increasingly powerful fallback methods:
unsquashfswith Offset Detection: Tries to find the SquashFS filesystem offset and extract it directly.binwalkAnalysis: Ifbinwalkis installed, it uses it to precisely identify the SquashFS offset for extraction.- Manual Hexdump Analysis: If all else fails, it scans the file's hex code to find the SquashFS magic bytes and extracts from there.
It determines the application's true name using this priority:
- Internal name from the
.desktopfile inside the AppImage --nameflag provided by the user- The AppImage filename
- If the app is not already installed, it creates a directory in
~/Applications/ - If it is installed, it updates the existing installation by replacing the contents
- This means downloading
Cursor-1.4.3.AppImageand laterCursor-1.5.0.AppImagewill update the same "Cursor" installation
It creates a .desktop file in ~/.local/share/applications that points to the extracted AppRun (or other executable), and installs an icon.
After installation, your file structure will look like:
~/Applications/cursor/ # Application directory (based on internal name)
├── cursor.AppImage # Original AppImage file
├── extracted/ # Extracted AppImage contents
│ ├── AppRun # Main executable
│ ├── cursor.desktop # Internal desktop file
│ ├── usr/ # Application files
│ └── ...
├── icon # Extracted icon file
└── .appimage-manager-meta # Manager metadata
~/.local/share/applications/cursor.desktop # System desktop entry
~/.local/share/icons/hicolor/256x256/apps/cursor.png # System icon
Clone the repository and make the script executable:
git clone https://github.com/drmikecrowe/appimage-extract-installer.git
cd appimage-extract-installer
chmod +x appimage-manager.shFor basic functionality, you only need a standard Linux environment. For the enhanced extraction features, you should install:
squashfs-tools: Providesunsquashfsfor the primary fallback extraction methodbinwalk: Provides the most reliable extraction method for problematic AppImages
On Arch/Manjaro:
sudo pacman -S --noconfirm squashfs-tools binwalkOptional utilities for better experience:
file: For detecting SVG vs PNG iconsrsync: For faster file copyingxdg-utils: For menu refreshdesktop-file-utils: For desktop integrationkbuildsycoca5(on KDE): For KDE menu refresh
./appimage-manager.sh install /path/to/YourApp.AppImageOptional flags:
--name "Custom Name": Override the application name (though it's recommended to rely on the internal name for idempotency)--exec-args "--foo --bar": Append extra arguments to theExecline in the.desktopfile
Examples:
# Basic installation
./appimage-manager.sh install ./Cursor-1.4.3.AppImage
# Override name
./appimage-manager.sh install ./SomeApp.AppImage --name "My App"
# Add execution arguments
./appimage-manager.sh install ./Editor.AppImage --exec-args "--debug --verbose"./appimage-manager.sh uninstall "AppName"./appimage-manager.sh list./appimage-manager.sh helpInstalling different versions of the same app will update the existing installation rather than creating duplicates:
./appimage-manager.sh install Cursor-1.4.3.AppImage # Installs "Cursor"
./appimage-manager.sh install Cursor-1.5.0.AppImage # Updates "Cursor" to new versionHandles problematic AppImages that fail with standard methods:
- Uses multiple fallback extraction techniques
- Works even when FUSE is unavailable or broken
- Handles corrupted or non-standard AppImage formats
- No
sudorequired - everything installs to your home directory - Proper desktop integration with KDE and GNOME
- Automatic icon extraction and installation
- Menu refresh for immediate availability
- Backs up the old AppImage during updates
- Atomic updates - if something goes wrong, the old version remains functional
- Clean uninstallation removes all traces
- Make sure the AppImage is executable:
chmod +x YourApp.AppImage - Install extraction tools:
sudo pacman -S squashfs-tools binwalk - Try running the AppImage directly first to see if it's corrupted
- Try refreshing the menu:
xdg-desktop-menu forceupdate - On KDE:
kbuildsycoca5 - Log out and back in
- Check if the desktop file was created:
ls ~/.local/share/applications/
- Check if the extracted executable exists and is executable
- Try running the extracted
AppRundirectly:~/Applications/[app-name]/extracted/AppRun - Check the desktop file for correct paths:
cat ~/.local/share/applications/[app-name].desktop
Contributions are welcome! Please feel free to submit issues, feature requests, or pull requests.
This project is licensed under the Apache License 2.0. See the LICENSE file for details.
Copyright 2025 Mike Crowe (drmikecrowe)