data: add app icon, desktop entry, and install script
This commit is contained in:
parent
668c73c8d2
commit
85b05a14bc
3 changed files with 99 additions and 0 deletions
31
install.sh
Executable file
31
install.sh
Executable file
|
|
@ -0,0 +1,31 @@
|
|||
#!/usr/bin/env bash
|
||||
# Install FeedTheMonkey system-wide (requires root or sudo).
|
||||
# Run after: cargo build --release
|
||||
|
||||
set -e
|
||||
|
||||
PREFIX="${PREFIX:-/usr/local}"
|
||||
BINARY="target/release/feedthemonkey"
|
||||
|
||||
if [ ! -f "$BINARY" ]; then
|
||||
echo "Binary not found. Run 'cargo build --release' first."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
install -Dm755 "$BINARY" "$PREFIX/bin/feedthemonkey"
|
||||
install -Dm644 data/net.jeena.FeedTheMonkey.desktop \
|
||||
"$PREFIX/share/applications/net.jeena.FeedTheMonkey.desktop"
|
||||
install -Dm644 data/icons/net.jeena.FeedTheMonkey.svg \
|
||||
"$PREFIX/share/icons/hicolor/scalable/apps/net.jeena.FeedTheMonkey.svg"
|
||||
|
||||
# Install GSettings schema
|
||||
install -Dm644 data/net.jeena.FeedTheMonkey.gschema.xml \
|
||||
"$PREFIX/share/glib-2.0/schemas/net.jeena.FeedTheMonkey.gschema.xml"
|
||||
glib-compile-schemas "$PREFIX/share/glib-2.0/schemas/"
|
||||
|
||||
# Update icon cache if gtk-update-icon-cache is available
|
||||
if command -v gtk-update-icon-cache &>/dev/null; then
|
||||
gtk-update-icon-cache -f -t "$PREFIX/share/icons/hicolor"
|
||||
fi
|
||||
|
||||
echo "Installed to $PREFIX"
|
||||
Loading…
Add table
Add a link
Reference in a new issue