Updated create and update appdir files to include Nebula-Desktop and Nebula-Controller files

This commit is contained in:
2026-02-01 21:29:13 +13:00
parent b725d5a672
commit 0137df60dd
2 changed files with 36 additions and 8 deletions
+19 -8
View File
@@ -14,8 +14,8 @@ fi
mkdir -p "$DEST" mkdir -p "$DEST"
cp -a "$SRC/." "$DEST/" cp -a "$SRC/." "$DEST/"
# Ensure launcher/binary exist # Ensure launcher/binary exist (prefer extracted run-nebula.sh as fallback)
if [ -f "$DEST/run-nebula.sh" ]; then if [ -f "$DEST/run-nebula.sh" ] && [ ! -f "$DEST/Nebula" ]; then
mv "$DEST/run-nebula.sh" "$DEST/Nebula" 2>/dev/null || true mv "$DEST/run-nebula.sh" "$DEST/Nebula" 2>/dev/null || true
fi fi
chmod +x "$DEST/Nebula" || true chmod +x "$DEST/Nebula" || true
@@ -76,14 +76,25 @@ if [ -f "$SCRIPT_DIR/appdir-example/nebula.desktop" ]; then
cp "$SCRIPT_DIR/appdir-example/nebula.desktop" "$DEST/nebula.desktop" cp "$SCRIPT_DIR/appdir-example/nebula.desktop" "$DEST/nebula.desktop"
cp "$SCRIPT_DIR/appdir-example/nebula.desktop" "$DEST/usr/share/applications/nebula.desktop" cp "$SCRIPT_DIR/appdir-example/nebula.desktop" "$DEST/usr/share/applications/nebula.desktop"
fi fi
# Ensure root launcher exists (from example if needed) # Ensure root launchers exist (from example if needed)
if [ -f "$SCRIPT_DIR/appdir-example/Nebula" ]; then if [ -f "$SCRIPT_DIR/appdir-example/Nebula-Desktop" ]; then
cp "$SCRIPT_DIR/appdir-example/Nebula" "$DEST/Nebula" cp "$SCRIPT_DIR/appdir-example/Nebula-Desktop" "$DEST/Nebula-Desktop"
chmod +x "$DEST/Nebula" || true chmod +x "$DEST/Nebula-Desktop" || true
fi
if [ -f "$SCRIPT_DIR/appdir-example/Nebula-Controller" ]; then
cp "$SCRIPT_DIR/appdir-example/Nebula-Controller" "$DEST/Nebula-Controller"
chmod +x "$DEST/Nebula-Controller" || true
fi
# Fallback: create Nebula as symlink to Nebula-Desktop
if [ ! -f "$DEST/Nebula" ] && [ -f "$DEST/Nebula-Desktop" ]; then
ln -sf "Nebula-Desktop" "$DEST/Nebula"
fi fi
# Fix permissions # Fix permissions
chmod -R a+r "$DEST/usr/share/icons/hicolor/256x256/apps" || true chmod -R a+r "$DEST/usr/share/icons/hicolor/256x256/apps" || true
chmod +x "$DEST/Nebula" || true chmod +x "$DEST/Nebula" "$DEST/Nebula-Desktop" "$DEST/Nebula-Controller" || true
echo "AppDir assembled at $DEST. Run with: $DEST/run-nebula.sh" echo "AppDir assembled at $DEST."
echo " Desktop mode: $DEST/Nebula-Desktop"
echo " Controller mode: $DEST/Nebula-Controller"
echo " Default: $DEST/Nebula (symlink to Nebula-Desktop)"
+17
View File
@@ -81,6 +81,23 @@ for file in "${FILES[@]}"; do
fi fi
done done
# Update main launcher scripts if present
echo ""
echo "🔄 Syncing launcher scripts..."
for launcher in "Nebula-Desktop" "Nebula-Controller"; do
if [ -f "$SCRIPT_DIR/nebula-appdir/$launcher" ]; then
cp "$SCRIPT_DIR/nebula-appdir/$launcher" "$APPDIR_ROOT/$launcher"
chmod +x "$APPDIR_ROOT/$launcher" || true
echo "$launcher"
fi
done
# Sync Nebula symlink if it exists
if [ -L "$SCRIPT_DIR/nebula-appdir/Nebula" ]; then
rm -f "$APPDIR_ROOT/Nebula"
ln -sf "Nebula-Desktop" "$APPDIR_ROOT/Nebula"
echo " ✓ Nebula (symlink)"
fi
# Sync directories # Sync directories
echo "" echo ""
echo "📁 Syncing directories..." echo "📁 Syncing directories..."