termius/PKGBUILD

60 lines
2.2 KiB
Bash
Raw Normal View History

2020-05-06 19:57:06 +00:00
# Maintainer: TBK <aur at jjtc dot eu>
# Contributor: TBK <aur at jjtc dot eu>
2019-06-11 00:17:45 +00:00
pkgname=termius
2020-09-08 08:30:47 +00:00
pkgver=6.4.1
2020-03-16 23:38:16 +00:00
pkgrel=1
2019-06-11 00:17:45 +00:00
pkgdesc="Desktop SSH Client"
url="https://www.termius.com/"
arch=('x86_64')
license=('custom')
2020-02-07 08:43:29 +00:00
depends=('libnotify' 'libappindicator-gtk3' 'libxtst' 'nss' 'libxss')
2019-06-11 00:17:45 +00:00
makedepends=('squashfs-tools')
2020-03-16 23:38:16 +00:00
# Get latest version + link from https://snapcraft.io/termius-app || snap info termius-app || run the following
2019-06-11 00:17:45 +00:00
# curl -H 'X-Ubuntu-Series: 16' https://api.snapcraft.io/api/v1/snaps/details/termius-app | jq '.download_url' -r
# curl -H 'X-Ubuntu-Series: 16' https://api.snapcraft.io/api/v1/snaps/details/termius-app | jq '.version' -r
source=(
2020-09-08 08:30:47 +00:00
"$pkgname-$pkgver.snap::https://api.snapcraft.io/api/v1/snaps/download/WkTBXwoX81rBe3s3OTt3EiiLKBx2QhuS_55.snap"
2019-06-11 00:17:45 +00:00
"termius.desktop"
"tos.html"
)
2020-09-08 08:30:47 +00:00
sha512sums=('edfc9fd3bfea73ddd76e51486ec1c7646c6548ad3be75231a29bbe3cdfa65f8af37b0f525d5faab91659cc1dbec027aa804d9dd3d71dad94e491b0178b645e09'
2020-04-17 21:20:18 +00:00
'9b0788a02b9bf371de07adec8f3e14f4db8bf83dae6dee60d91027d8ba09cbab253b8b714f980d5c62b72d97e4ac11e6c3985139322bdceaad9f2f0232427656'
'53f9c61fba12b72817c5e7f4e0ac520489265fbf425fa46f13129da66632b41a2a128072d9e0e64e37e4e8feb8424bc1c15eed127d630314e6459ceb2dbafb4b')
2019-06-11 00:17:45 +00:00
prepare() {
2020-04-17 21:20:18 +00:00
mkdir $pkgname
unsquashfs -f -d $pkgname $pkgname-$pkgver.snap
2019-06-11 00:17:45 +00:00
}
package() {
# Option 1 - copy only the needed files ~183 MiB
2020-04-17 21:20:18 +00:00
mkdir -p "$pkgdir"/opt/$pkgname
2019-06-11 00:17:45 +00:00
2020-04-17 21:20:18 +00:00
cd "$srcdir"/$pkgname
2019-06-11 00:17:45 +00:00
2020-04-17 21:20:18 +00:00
cp -r \
icudtl.dat \
2019-06-11 00:17:45 +00:00
libffmpeg.so \
locales \
resources \
resources.pak \
termius-app \
v8_context_snapshot.bin \
2020-04-17 21:20:18 +00:00
"$pkgdir"/opt/$pkgname
2019-06-11 00:17:45 +00:00
cd "$srcdir"
# Option 2 - copy all files from the .snap file ~503 MiB
#mkdir -p "$pkgdir"/opt/
2020-04-17 21:20:18 +00:00
#cp -r "$srcdir"/$pkgname "$pkgdir"/opt/$pkgname
2019-06-11 00:17:45 +00:00
2020-04-17 21:20:18 +00:00
find "$pkgdir"/opt/$pkgname/ -type f -exec chmod 644 {} \;
chmod 755 "$pkgdir"/opt/$pkgname/termius-app
2019-06-11 00:17:45 +00:00
2020-04-17 21:20:18 +00:00
mkdir -p "$pkgdir"/usr/bin
ln -sf /opt/$pkgname/termius-app "$pkgdir"/usr/bin/$pkgname
install -Dm0644 tos.html "$pkgdir"/usr/share/licenses/$pkgname/tos.html
install -Dm0644 $pkgname.desktop "$pkgdir"/usr/share/applications/$pkgname.desktop
install -Dm0644 $pkgname/meta/gui/icon.png "$pkgdir"/usr/share/pixmaps/$pkgname.png
2019-06-11 00:17:45 +00:00
}