Add screenshots, update metainfo, and fix AppImage build script
- Add 18 screenshots sorted by workflow order to data/screenshots/ - Update metainfo with actual screenshot entries and correct dimensions - Fix build script to copy all hicolor icon sizes and use linuxdeploy --output - Add exported icon PNGs to icons/
This commit is contained in:
@@ -36,14 +36,20 @@ mkdir -p "$APP_DIR/usr/share/metainfo"
|
||||
cp "target/$BUILD_TYPE/pixstrip-gtk" "$APP_DIR/usr/bin/pixstrip-gtk"
|
||||
cp "target/$BUILD_TYPE/pixstrip-cli" "$APP_DIR/usr/bin/pixstrip"
|
||||
|
||||
# Step 4: Copy desktop file, icon, metainfo
|
||||
# Step 4: Copy desktop file, icons, metainfo
|
||||
cp "data/$APP_ID.desktop" "$APP_DIR/usr/share/applications/"
|
||||
cp "data/icons/hicolor/scalable/apps/$APP_ID.svg" "$APP_DIR/usr/share/icons/hicolor/scalable/apps/"
|
||||
cp "data/$APP_ID.desktop" "$APP_DIR/"
|
||||
cp "data/$APP_ID.metainfo.xml" "$APP_DIR/usr/share/metainfo/"
|
||||
|
||||
# Symlinks required by AppImage spec
|
||||
ln -sf "usr/share/applications/$APP_ID.desktop" "$APP_DIR/$APP_ID.desktop"
|
||||
ln -sf "usr/share/icons/hicolor/scalable/apps/$APP_ID.svg" "$APP_DIR/$APP_ID.svg"
|
||||
# Copy all hicolor icon sizes
|
||||
for size_dir in data/icons/hicolor/*/apps; do
|
||||
size=$(basename "$(dirname "$size_dir")")
|
||||
mkdir -p "$APP_DIR/usr/share/icons/hicolor/$size/apps"
|
||||
cp "$size_dir"/$APP_ID.* "$APP_DIR/usr/share/icons/hicolor/$size/apps/" 2>/dev/null || true
|
||||
done
|
||||
|
||||
# Top-level icon for AppImage spec
|
||||
cp "data/icons/hicolor/256x256/apps/$APP_ID.png" "$APP_DIR/$APP_ID.png"
|
||||
|
||||
# Step 5: Create AppRun
|
||||
cat > "$APP_DIR/AppRun" << 'APPRUN'
|
||||
@@ -78,28 +84,15 @@ if [[ ! -x "$TOOLS_DIR/linuxdeploy-plugin-gtk.sh" ]]; then
|
||||
chmod +x "$TOOLS_DIR/linuxdeploy-plugin-gtk.sh"
|
||||
fi
|
||||
|
||||
# Use linuxdeploy to bundle dependencies
|
||||
# Use linuxdeploy to bundle dependencies and create AppImage
|
||||
export DEPLOY_GTK_VERSION=4
|
||||
"$TOOLS_DIR/linuxdeploy" \
|
||||
--appdir "$APP_DIR" \
|
||||
--desktop-file "$APP_DIR/usr/share/applications/$APP_ID.desktop" \
|
||||
--icon-file "$APP_DIR/usr/share/icons/hicolor/scalable/apps/$APP_ID.svg" \
|
||||
--plugin gtk
|
||||
|
||||
# Step 7: Build the AppImage
|
||||
echo "--- Creating AppImage ---"
|
||||
|
||||
# Download appimagetool if not present
|
||||
if [[ ! -x "$TOOLS_DIR/appimagetool" ]]; then
|
||||
echo "Downloading appimagetool..."
|
||||
wget -q -O "$TOOLS_DIR/appimagetool" \
|
||||
"https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage"
|
||||
chmod +x "$TOOLS_DIR/appimagetool"
|
||||
fi
|
||||
|
||||
VERSION="0.1.0"
|
||||
"$TOOLS_DIR/appimagetool" "$APP_DIR" "Pixstrip-${VERSION}-x86_64.AppImage"
|
||||
--icon-file "$APP_DIR/usr/share/icons/hicolor/256x256/apps/$APP_ID.png" \
|
||||
--plugin gtk \
|
||||
--output appimage
|
||||
|
||||
echo ""
|
||||
echo "=== AppImage built: Pixstrip-${VERSION}-x86_64.AppImage ==="
|
||||
echo "Size: $(du -h "Pixstrip-${VERSION}-x86_64.AppImage" | cut -f1)"
|
||||
echo "=== AppImage built ==="
|
||||
ls -lh Pixstrip-*.AppImage 2>/dev/null || echo "Note: output filename may vary."
|
||||
|
||||
Reference in New Issue
Block a user