### Configure and Install qmake Project to AppDir Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst Prepare a qmake project for installation into an AppDir. This involves creating a build directory, running qmake, building the application, and then installing it. ```bash git clone https://github.com/linuxdeploy/QtQuickApp.git cd QtQuickApp mkdir build cd build qmake .. make -j$(nproc) ``` -------------------------------- ### Prepare AppDir with make install Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst Use 'make install' with INSTALL_ROOT set to AppDir to prepare the application directory structure. ```bash make install INSTALL_ROOT=AppDir ``` -------------------------------- ### Install obs-service-appimage on openSUSE Leap Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/hosted-services/opensuse-build-service.rst Install the obs-service-appimage package on openSUSE Leap 42.1. This involves adding a specific repository, refreshing package lists, and then installing the service. ```shell zypper addrepo http://download.opensuse.org/repositories/openSUSE:Tools/openSUSE_42.1/openSUSE:Tools.repo zypper ref zypper in obs-service-appimage ``` -------------------------------- ### Configure and Install CMake Project to AppDir Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst Use CMake to configure a project, build it, and then 'install' its components into an 'AppDir' directory. This method requires the application to have install configurations set up in its build system. ```bash git clone https://github.com/linuxdeploy/QtQuickApp.git cd QtQuickApp mkdir build cd build cmake .. -DCMAKE_INSTALL_PREFIX=/usr make -j$(nproc) make install DESTDIR=AppDir ``` -------------------------------- ### Build QtQuickApp with qmake Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst This script demonstrates building an AppImage for QtQuickApp using qmake and the 'make install' strategy. It's designed to be run in an isolated environment. ```bash #!/bin/bash set -e # Create a temporary directory and move into it TMPDIR=$(mktemp -d) cd "$TMPDIR" # Clone the QtQuickApp repository git clone https://github.com/linuxdeploy/QtQuickApp cd QtQuickApp # Create the AppDir mkdir -p ../AppDir/usr/bin \ ../AppDir/usr/share/icons/hicolor/scalable/apps \ ../AppDir/usr/share/applications # Build the application using qmake and install it into AppDir qmake .. make install INSTALL_ROOT=../AppDir # Copy the desktop file and icon cp ../../usr/share/applications/quick.desktop ../AppDir/usr/share/applications/ cp ../../usr/share/icons/hicolor/scalable/apps/quick.svg ../AppDir/usr/share/icons/hicolor/scalable/apps/ # Create the AppImage # Note: This assumes linuxdeploy-x86_64.AppImage is in the parent directory ../../linuxdeploy-x86_64.AppImage --appdir ../AppDir --output appimage # Move the AppImage to the current directory mv *.AppImage ../.. # Clean up the temporary directory cd ../.. rm -rf "$TMPDIR" ``` -------------------------------- ### Build QtQuickApp with CMake Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst This script demonstrates building an AppImage for QtQuickApp using CMake and the 'make install' strategy. It's effectively the same as the qmake version but uses CMake for building. ```bash #!/bin/bash set -e # Create a temporary directory and move into it TMPDIR=$(mktemp -d) cd "$TMPDIR" # Clone the QtQuickApp repository git clone https://github.com/linuxdeploy/QtQuickApp cd QtQuickApp # Create the AppDir mkdir -p ../../AppDir/usr/bin \ ../../AppDir/usr/share/icons/hicolor/scalable/apps \ ../../AppDir/usr/share/applications # Build the application using CMake and install it into AppDir cmake . -DCMAKE_INSTALL_PREFIX=../../AppDir/usr make install # Copy the desktop file and icon cp ../../usr/share/applications/quick.desktop ../../AppDir/usr/share/applications/ cp ../../usr/share/icons/hicolor/scalable/apps/quick.svg ../../AppDir/usr/share/icons/hicolor/scalable/apps/ # Create the AppImage # Note: This assumes linuxdeploy-x86_64.AppImage is in the parent directory ../../linuxdeploy-x86_64.AppImage --appdir ../../AppDir --output appimage # Move the AppImage to the current directory mv *.AppImage ../.. # Clean up the temporary directory cd ../.. rm -rf "$TMPDIR" ``` -------------------------------- ### Build HTML Documentation with Sphinx Source: https://github.com/appimage/docs.appimage.org/blob/master/README.rst Use this command to build the HTML version of the documentation using Sphinx. Ensure you have Sphinx installed and configured. ```bash make html ``` -------------------------------- ### Install FUSE on openSUSE Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/troubleshooting/fuse.rst Installs the necessary FUSE packages, fuse and libfuse2, on openSUSE systems. ```bash > sudo zypper install fuse libfuse2 ``` -------------------------------- ### AppImage Build Configuration Example Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/hosted-services/opensuse-build-service.rst This is a configuration snippet for building an AppImage. It shows how to specify packages, source code repositories (Git, SVN, CVS, Mercurial, Bazaar), and additional files to include. ```yaml build: packages: - [SINGLE BINARY PACKAGE NAME] git: # can be also svn, cvs, hg, bzr - [URL TO SCM REPOSITORY] files: - [URL TO A RESOURCE] ``` -------------------------------- ### Build AppImage from Source with Dependencies Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/hosted-services/opensuse-build-service.rst Configure appimage.yml to build an AppImage from source. This example includes build-time package dependencies and a git repository source. ```yaml app: QtQuickApp build: packages: - linuxdeployqt - pkgconfig(Qt5Quick) git: - https://github.com/probonopd/QtQuickApp.git script: - cd $BUILD_SOURCE_DIR/QtQuickApp* - qmake-qt5 PREFIX=/usr - make INSTALL_ROOT=$BUILD_APPDIR install - unset QTDIR; unset QT_PLUGIN_PATH ; unset LD_LIBRARY_PATH ``` -------------------------------- ### Resolve application directory path Source: https://github.com/appimage/docs.appimage.org/blob/master/source/reference/best-practices.rst Use `QCoreApplication::applicationDirPath()` to get the application's directory and construct relative paths for resources. This ensures compatibility with relocatable installations like AppImages. ```cpp QString path = QCoreApplication::applicationDirPath(); path.append("../share/kaidan/images/"); ``` -------------------------------- ### Travis CI Configuration for AppImage Build Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst This is an example .travis.yml file demonstrating how to integrate the AppImage build scripts into a Travis CI pipeline. It focuses on keeping the script section concise. ```yaml language: minimal sudo: required install: - apt-get update && apt-get install -y --no-install-recommends git script: # This script section is intentionally kept short. # The actual build logic is in the separate bash scripts (e.g., travis/build-with-qmake.sh). # This example assumes the build script is in the root directory. - ./travis/build-with-qmake.sh notifications: email: false ``` -------------------------------- ### Install FUSE on Arch Linux Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/troubleshooting/fuse.rst Install the fuse2 package on Arch Linux. Ensure the fusermount binary has correct permissions. ```shell sudo pacman -S fuse2 ``` -------------------------------- ### Use Debian Repository for Ingredients Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Specify Debian distribution and repositories to pull packages from. This example uses Ubuntu Xenial and includes OpenSUSE repositories for dependencies. ```yaml ingredients: dist: xenial sources: - deb http://archive.ubuntu.com/ubuntu/ xenial main universe - deb http://download.opensuse.org/repositories/isv:/KDAB/xUbuntu_16.04/ / ``` -------------------------------- ### Install FUSE for Cross-Architecture AppImages Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/troubleshooting/fuse.rst Installs FUSE 2.x runtime libraries for specific architectures (i386 or armhf) when running 32-bit AppImages on a 64-bit system. ```bash > sudo apt-get install libfuse2:i386 > sudo apt-get install libfuse2:armhf ``` -------------------------------- ### Pretend Exact Dependency Versions Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Use the 'pretend' key to specify exact versions of dependencies that should be considered installed. This bypasses package manager checks for specific versions. ```yaml ingredients: dist: xenial sources: - deb http://archive.ubuntu.com/ubuntu/ xenial main universe ppas: - otto-kesselgulasch/gimp-edge pretend: - libcups2 1.7.2-0ubuntu1 ``` -------------------------------- ### Start AppImage Update Process Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/optional/updates.rst Initiate the AppImage update process. Updates are performed in a separate thread automatically, allowing for UI updates without blocking. ```cpp updater.start() // isDone() returns true as soon as the update has finished ``` -------------------------------- ### AppImage Recipe for Mu Python Editor Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst This YAML recipe configures the build process for the Mu Python editor AppImage. It specifies distribution, repositories, packages, and includes custom scripts for downloading assets, setting up a virtual environment, installing the editor, and creating a desktop entry. ```yaml app: mu.codewith.editor ingredients: dist: xenial sources: - deb http://us.archive.ubuntu.com/ubuntu/ xenial xenial-updates xenial-security main universe - deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates main universe - deb http://us.archive.ubuntu.com/ubuntu/ xenial-security main universe packages: - python3.4-venv script: - wget -c https://raw.githubusercontent.com/mu-editor/mu/master/conf/mu.codewith.editor.png - wget -c https://raw.githubusercontent.com/mu-editor/mu/master/conf/mu.appdata.xml script: - cp ../mu.codewith.editor.png ./usr/share/icons/hicolor/256x256/ - cp ../mu.codewith.editor.png . - mkdir -p usr/share/metainfo/ ; cp ../mu.appdata.xml usr/share/metainfo/ - virtualenv --python=python3 usr - ./usr/bin/pip3 install mu-editor - cat > usr/share/applications/mu.codewith.editor.desktop <<\EOF - [Desktop Entry] - Type=Application - Name=Mu - Comment=A Python editor for beginner programmers - Icon=mu.codewith.editor - Exec=python3 bin/mu-editor %F - Terminal=false - Categories=Application;Development; - Keywords=Python;Editor;microbit;micro:bit; - StartupWMClass=mu - MimeType=text/x-python3;text/x-python3; - EOF - cp usr/share/applications/mu.codewith.editor.desktop . - usr/bin/pip3 freeze | grep "mu-editor" | cut -d "=" -f 3 >> ../VERSION ``` -------------------------------- ### Install FUSE on Chromium OS/Crostini Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/troubleshooting/fuse.rst Install the FUSE package on Chromium OS, Chrome OS, or Crostini. This enables FUSE functionality starting from release 73. ```shell sudo apt install fuse ``` -------------------------------- ### Enable Input Plugin Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/linuxdeploy-user-guide.rst Activate an input plugin, such as 'qt', by specifying it with the --plugin flag. Ensure the plugin is available to linuxdeploy. ```bash > ./linuxdeploy-x86_64.AppImage --appdir AppDir <...> --plugin qt ``` -------------------------------- ### Download and Prepare AppImage Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/portable-mode.rst Download an AppImage, make it executable, and create a configuration directory for portable mode. ```shell $ wget -c "https://bintray.com/probono/AppImages/download_file?file_path=Leafpad-0.8.18.1.glibc2.4-x86_64.AppImage" -O Leafpad-0.8.18.1.glibc2.4-x86_64.AppImage $ chmod a+x Leafpad-0.8.18.1.glibc2.4-x86_64.AppImage $ mkdir Leafpad-0.8.18.1.glibc2.4-x86_64.AppImage.config ``` -------------------------------- ### Run linuxdeploy to create AppDir Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst Execute linuxdeploy with the --appdir flag to create or update the AppDir, bundling necessary resources. ```bash ./linuxdeploy-x86_64.AppImage --appdir AppDir ``` -------------------------------- ### Create a .desktop File Manually Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst This is a workaround for applications missing a .desktop file. It demonstrates how to create a basic .desktop file using a heredoc, specifying essential fields like Name, Icon, and Exec. ```yaml script: - # Workaround for: - # https://bugzilla.mozilla.org/show_bug.cgi?id=296568 - cat > firefox.desktop < yum --enablerepo=epel install fuse-sshfs ``` -------------------------------- ### Install FUSE 2.x on Recent Ubuntu/Debian Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/troubleshooting/fuse.rst Installs the libfuse2 package on recent Ubuntu (>=22.04) and Debian distributions to enable FUSE 2.x alongside FUSE 3.x. ```bash > sudo apt install libfuse2 ``` -------------------------------- ### Install FUSE 2.x on Ubuntu/Debian Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/troubleshooting/fuse.rst Install the libfuse2 package for FUSE 2.x compatibility on Ubuntu (pre-22.04) and Debian systems. Note: On Ubuntu 24.04, the package is named libfuse2t64. ```bash > sudo apt-get install libfuse2 ``` -------------------------------- ### Build HTML Documentation with Convenience Script Source: https://github.com/appimage/docs.appimage.org/blob/master/README.rst This script provides a convenient way to set up a local isolated Sphinx environment and build the HTML documentation. It acts as a wrapper for the Makefile. ```bash ./make.sh html ``` -------------------------------- ### Download and run testappimage script Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/testing.rst Use this script to automate testing of AppImages on Ubuntu-like and Fedora-like Live ISOs. Ensure you have the ISO file and the AppImage you want to test. ```shell $ wget https://raw.githubusercontent.com/AppImage/AppImageKit/master/testappimage $ sudo bash testappimage /path/to/elementary-0.2-20110926.iso AppImageAssistant.AppImage ``` -------------------------------- ### Download and make linuxdeploy executable Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst Download the linuxdeploy AppImage and make it executable using chmod. ```bash wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage chmod +x linuxdeploy-x86_64.AppImage ``` -------------------------------- ### Set Environment Variable for Plugin Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/linuxdeploy-user-guide.rst Set environment variables before calling linuxdeploy to change plugin behavior. This example sets the FOOBAR_VAR for the 'foobar' plugin. ```bash # set the environment variable > export FOOBAR_VAR=example # call linuxdeploy with the respective plugin enabled > ./linuxdeploy-x86_64.AppImage --appdir AppDir <...> --plugin foobar ``` -------------------------------- ### Create AppImage Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/mac.rst Use appimagetool to bundle your application into an AppImage file. ```bash appimagetool my.AppDir my.AppImage ``` -------------------------------- ### Clone and run appimage-testsuite Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/testing.rst Clone the appimage-testsuite repository to test your AppImage on various Linux distributions using Docker containers. This requires Docker to be installed on your system. ```shell $ git clone https://github.com/aferrero2707/appimage-testsuite.git $ cd appimage-testsuite $ ./run.sh PATH_TO_APPIMAGE/package.AppImage ubuntu-18.04 # /aitest/aitest.sh ``` -------------------------------- ### List Available Plugins Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/linuxdeploy-user-guide.rst Use the --list-plugins flag to see all plugins visible to linuxdeploy. This is helpful for debugging plugin issues. ```bash > ./linuxdeploy-x86_64.AppImage --list-plugins ``` -------------------------------- ### Bundle Executable with linuxdeploy Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/linuxdeploy-user-guide.rst Use the --executable flag to bundle a native binary executable into the AppDir. Ensure the output format is specified, such as 'appimage'. ```bash > ./linuxdeploy-x86_64.AppImage --appdir AppDir --executable ./foobar <...> --output appimage ``` -------------------------------- ### Basic .desktop file for an application Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/manual.rst A minimal `.desktop` file entry for an application. Ensure `Exec` matches your executable name and `Icon` matches your icon file. Add `Terminal=true` for command-line tools. ```ini [Desktop Entry] Name=MyApp Exec=myapp Icon=myapp Type=Application Categories=Utility; ``` -------------------------------- ### Build AppImage with pkg2appimage Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Use this command to build an AppImage from a .yml description file. Ensure you are in the correct directory and have the necessary permissions. ```shell bash -ex ./pkg2appimage recipes/XXX.yml ``` -------------------------------- ### Initialize Git Submodules Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/optional/updates.rst After cloning a repository with submodules, run this command to initialize them. This is necessary for AppImageUpdate and its dependencies. ```shell git submodule update --init --recursive ``` -------------------------------- ### Move .desktop File to Top-Level Directory Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Use this when an application includes a .desktop file but it's not in the standard location. This example extracts an archive and then moves the .desktop file to the AppDir's root. ```yaml script: - tar xf ../fritzing* -C usr/bin/ --strip 1 - mv usr/bin/fritzing.desktop . ``` -------------------------------- ### Modify run.sh for host IP address Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/testing.rst If the automatic host IP detection fails in the appimage-testsuite, you may need to manually set the IP address within the run.sh script. This example shows how to find and set the IP for en0. ```shell IP=$(ifconfig en0 | grep inet | awk '$1=="inet" {print $2}') ``` -------------------------------- ### Build AppImage with linuxdeploy Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/native-binaries.rst Use this command to create an AppImage from an AppDir using the linuxdeploy tool with the appimage output plugin enabled. ```bash ./linuxdeploy-x86_64.AppImage --appdir AppDir --output appimage ``` -------------------------------- ### Bundle Non-Qt Libraries with linuxdeployqt Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/hosted-services/opensuse-build-service.rst Use linuxdeployqt to bundle non-Qt libraries into your AppDir. Specify the application's desktop files and the source directory for QML files. Verbose output is enabled for debugging. ```shell linuxdeployqt $BUILD_APPDIR/usr/share/applications/*.desktop -qmldir=$BUILD_SOURCE_DIR/ -bundle-non-qt-libs -verbose=2 ``` -------------------------------- ### Copy Executable from Downloaded Archive Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst This snippet is for when binary ingredients are downloaded archives. It shows how to download, unpack, and then copy the main executable from the archive into the AppDir's usr/bin. ```yaml ingredients: script: - wget -c "https://telegram.org/dl/desktop/linux" --trust-server-names - tar xf tsetup.*.tar.xz script: - cp ../Telegram/Telegram ./usr/bin/telegram-desktop ``` -------------------------------- ### Specify Ubuntu PPAs in Ingredients Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Use the 'ppas' key to list Ubuntu Personal Package Archives. This is an alternative to manually adding sources.list entries. ```yaml ppas: - geany-dev/ppa ``` -------------------------------- ### Execute Custom Scripts for Ingredient Retrieval Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst The 'script' key allows arbitrary shell commands to fetch or prepare binary ingredients. This is useful for downloading files from URLs or setting up complex build environments. ```yaml ingredients: script: - URL=$(wget -q https://www.fosshub.com/JabRef.html -O - | grep jar | cut -d '"' -f 10) - wget -c "$URL" - wget -c --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u66-b17/jre-8u66-linux-x64.tar.gz ``` -------------------------------- ### Enable Output Plugin Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/from-source/linuxdeploy-user-guide.rst Enable an output plugin, like the 'appimage' plugin, using the --output flag. This is commonly used for generating AppImages. ```bash > ./linuxdeploy-x86_64.AppImage <...> --output appimage ``` -------------------------------- ### Include Local Deb Files Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Specify local .deb files or all .deb files in a directory using the 'debs' key. Ensure files are present on the build system. ```yaml ingredients: dist: xenial sources: - deb http://us.archive.ubuntu.com/ubuntu/ xenial main universe debs: - /home/area42/kdenlive.deb - /home/area42/kdenlive/* ``` -------------------------------- ### Extract and Move Executable from .deb Package Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Use this when .deb packages are specified as ingredients. It demonstrates downloading a .deb, extracting its contents, moving the main executable to the standard usr/bin location, and updating the .desktop file. ```yaml ingredients: dist: xenial sources: - deb http://archive.ubuntu.com/ubuntu/ xenial main universe script: - DLD=$(wget -q "https://github.com/feross/webtorrent-desktop/releases/" -O - | grep _amd64.deb | head -n 1 | cut -d '"' -f 2) - wget -c "https://github.com/$DLD" script: - mv opt/webtorrent-desktop/* usr/bin/ - sed -i -e 's|/opt/webtorrent-desktop/||g' webtorrent-desktop.desktop ``` -------------------------------- ### Include All Deb Files from a Local Directory Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst Use '/*' at the end of the path to include all .deb files within a specified local directory. ```yaml - /path/to/local/repo/* ``` -------------------------------- ### Display Existing OBS Token Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/hosted-services/opensuse-build-service.rst If a token has already been generated for the Open Build Service (OBS), this command can be used to display it. ```shell osc token ``` -------------------------------- ### Initialize Updater Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/optional/updates.rst Instantiate the Updater class with the path to the AppImage file. ```cpp using namespace appimage::update; using namespace std; Updater updater("test.AppImage"); ``` -------------------------------- ### Run AppImage in Portable Mode Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/portable-mode.rst Execute the AppImage. Any configuration changes will be saved in the '.config' directory. ```shell $ ./Leafpad-0.8.18.1.glibc2.4-x86_64.AppImage ``` -------------------------------- ### Travis CI configuration for uploading AppImages Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/hosted-services/travis-ci.rst This configuration snippet is added to your .travis.yml file. It downloads the upload.sh script and executes it after a successful build to upload artifacts from the 'out/' directory. It also excludes builds for tags created by the upload process. ```yaml after_success: - ls -lh out/* # Assuming you have some files in out/ that you would like to upload - wget -c https://github.com/probonopd/uploadtool/raw/master/upload.sh - bash upload.sh out/* branches: except: - # Do not build tags that we create when we upload to GitHub Releases - /^(?i:continuous)$/ ``` -------------------------------- ### Copy and Modify Desktop Entry for FBReader Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst This snippet demonstrates how to copy a desktop entry file, modify its Exec, Name, and Icon fields using sed, and then move the executable. This is typically part of an AppImage recipe's build script. ```bash cp ./usr/share/applications/FBReader.desktop fbreader.desktop sed -i -e 's|Exec=FBReader|Exec=fbreader|g' fbreader.desktop sed -i -e 's|Name=.*|Name=FBReader|g' fbreader.desktop sed -i -e 's|Icon=.*|Icon=fbreader|g' fbreader.desktop mv usr/bin/FBReader usr/bin/fbreader cp usr/share/pixmaps/FBReader.png fbreader.png ``` -------------------------------- ### Mount Type 2 AppImage with root and offset Source: https://github.com/appimage/docs.appimage.org/blob/master/source/user-guide/run-appimages.rst For type 2 AppImages, use the 'mount' command with root permissions and the offset obtained via '--appimage-offset'. You need to create a mountpoint. Remember to unmount manually. ```bash > mkdir mountpoint > my.AppImage --appimage-offset > 123456 > sudo mount my.AppImage mountpoint/ -o offset=123456 # you can now inspect the contents > sudo umount mountpoint/ ``` -------------------------------- ### Watch Documentation Changes with Sphinx Autobuild Source: https://github.com/appimage/docs.appimage.org/blob/master/README.rst Use this command to enable live-reloading for documentation development. It sets up a webserver that rebuilds the site on changes and reloads the browser automatically. ```bash ./make.sh watch ``` -------------------------------- ### Include a Single Local Deb File Source: https://github.com/appimage/docs.appimage.org/blob/master/source/packaging-guide/converting-binary-packages/pkg2appimage.rst A simplified way to include a single local .deb file. ```yaml - /path/to/file.deb ```