blob: 0416e449c0490188f71c06c52548568d896fbe37 (
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
|
# Maintainer: Ben Towali <bentowalii@gmail.com>
pkgname=raindrop
pkgver='5.6.50'
pkgrel=1
pkgdesc="All-in-one bookmark manager"
arch=('x86_64')
url="https://raindrop.io"
license=('MIT')
depends=()
makedepends=('squashfs-tools')
provides=(raindrop)
install=
_snapid="B8ZjYQVKEem99E5WjVMGUr75feAUrnH5"
_snaprev="25"
source=("https://api.snapcraft.io/api/v1/snaps/download/${_snapid}_${_snaprev}.snap")
sha512sums=("59cda3b792b9f3a16cf8ce4db13edc4d8d57dcd12feb7190e98bf4c4b1da6704ffc35468c1667c998f27a8185437e132bfc5f63340bdbcbfad5653fece34d5c9")
prepare() {
echo "Extracting snap file..."
unsquashfs -q -f -d "${srcdir}/${pkgname}" "${_snapid}_${_snaprev}.snap"
}
package() {
# Install Files
install -d "${pkgdir}/opt/${pkgname}"
cp -r "${srcdir}/${pkgname}/." "${pkgdir}/opt/${pkgname}"
# Desktop Entry
sed -i 's|${SNAP}/meta/gui/icon.png|raindrop|g' "${pkgdir}/opt/${pkgname}/meta/gui/${pkgname}.desktop"
install -Dm644 "${pkgdir}/opt/${pkgname}/meta/gui/${pkgname}.desktop" -t "${pkgdir}/usr/share/applications"
install -Dm644 "${pkgdir}/opt/${pkgname}/meta/gui/icon.png" "${pkgdir}/usr/share/pixmaps/${pkgname}.png"
# Clean up unnecessary files
rm -rf "${pkgdir}/opt/${pkgname}"/{data-dir,gnome-platform,lib,meta,scripts,usr,*.sh}
# Symlink binary to /usr/bin
install -d "${pkgdir}/usr/bin"
ln -s "/opt/${pkgname}/${pkgname}" "${pkgdir}/usr/bin"
}
|