blob: ae7f5e656c0af82c7a8117f51f6bdc1a116f5689 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
# Maintainer: ComputerElite <ComputerElite.dev@gmail.com>
pkgname=shock-alarm
pkgver=0.0.14
pkgrel=1
pkgdesc="A flutter app for controlling OpenShock devices"
arch=('x86_64')
url="https://github.com/ComputerElite/ShockAlarmApp"
license=('GPL3')
depends=(
'gtk3'
'libnotify'
'libsystemd'
'xdg-utils'
)
source=("https://github.com/ComputerElite/ShockAlarmApp/releases/download/${pkgver}/shock_alarm_linux_x64_refs.tags.${pkgver}.tar.gz")
sha256sums=('SKIP')
package() {
# Create installation directories
install -d "$pkgdir/opt/$pkgname"
install -d "$pkgdir/usr/bin"
# Extract and copy release files
tar -xzf "$srcdir/shock_alarm_linux_x64_refs.tags.${pkgver}.tar.gz" -C "$pkgdir/opt/$pkgname"
# Create symlink for binary
ln -s "/opt/$pkgname/shock_alarm" "$pkgdir/usr/bin/shock-alarm"
# Desktop file handling (create if not included in release)
install -d "$pkgdir/usr/share/applications"
cat << EOF > "$pkgdir/usr/share/applications/shock-alarm.desktop"
[Desktop Entry]
Name=Shock Alarm
Comment=${pkgdesc}
Exec=/usr/bin/shock-alarm
Icon=shock-alarm
Terminal=false
Type=Application
Categories=Utility;
EOF
# Icon handling (create if not included in release)
install -d "$pkgdir/usr/share/icons/hicolor/512x512/apps"
cp "$pkgdir/opt/$pkgname/data/flutter_assets/icon.png" \
"$pkgdir/usr/share/icons/hicolor/512x512/apps/shock-alarm.png"
# License file (if included in release)
if [ -f "$pkgdir/opt/$pkgname/LICENSE" ]; then
install -Dm644 "$pkgdir/opt/$pkgname/LICENSE" \
"$pkgdir/usr/share/licenses/$pkgname/LICENSE"
fi
}
|