desktop-chat-app/scripts/postinstall.sh
Lilith efffde48cd feat(startup): add service startup screen and launcher scripts
Add visual startup screen showing service initialization progress:
- ServiceStartupScreen displays each service's startup status
- ServiceManager gains extended service state tracking
- Launcher scripts for desktop integration and post-install hooks

Scripts:
- chat-launcher.sh: Desktop entry launcher with wayland fallback
- postinstall.sh: Create desktop entry and symlink
- postremove.sh: Cleanup desktop entry and symlink

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 20:25:01 -08:00

31 lines
881 B
Bash
Executable file

#!/bin/bash
# Lilith AI Desktop Chat - Post-installation script
# Called by dpkg after package installation
set -e
# Install location from electron-builder
INSTALL_DIR="/opt/Lilith AI Desktop Chat"
CLI_SOURCE="$INSTALL_DIR/resources/chat"
CLI_TARGET="/usr/local/bin/chat"
# Create symlink for the chat command
if [[ -f "$CLI_SOURCE" ]]; then
ln -sf "$CLI_SOURCE" "$CLI_TARGET"
chmod +x "$CLI_TARGET"
echo "Installed 'chat' command to $CLI_TARGET"
else
echo "Warning: CLI launcher not found at $CLI_SOURCE" >&2
fi
# Update desktop database if available
if command -v update-desktop-database &> /dev/null; then
update-desktop-database /usr/share/applications 2>/dev/null || true
fi
# Update icon cache if available
if command -v gtk-update-icon-cache &> /dev/null; then
gtk-update-icon-cache -f -t /usr/share/icons/hicolor 2>/dev/null || true
fi
exit 0