2022-10-19 16:15:04 +00:00
|
|
|
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
|
|
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
|
|
|
|
|
|
pkgname=caprine
|
2023-01-11 13:23:51 +00:00
|
|
|
pkgver=2.57.0
|
2023-03-31 20:26:25 +00:00
|
|
|
pkgrel=1
|
2022-10-19 16:15:04 +00:00
|
|
|
pkgdesc="Elegant Facebook Messenger desktop app"
|
2023-11-23 16:37:50 +00:00
|
|
|
# blocked by caprine
|
|
|
|
#arch="noarch"
|
2022-10-19 16:15:04 +00:00
|
|
|
url="https://github.com/sindresorhus/caprine"
|
|
|
|
license="MIT"
|
|
|
|
depends="electron"
|
2023-05-05 22:47:24 +00:00
|
|
|
makedepends="npm findutils coreutils"
|
2022-10-19 20:18:42 +00:00
|
|
|
options="!check"
|
2023-03-31 20:26:25 +00:00
|
|
|
source="
|
|
|
|
$pkgname-$pkgver.tar.gz::https://github.com/sindresorhus/caprine/archive/refs/tags/v$pkgver.tar.gz
|
|
|
|
caprine.desktop
|
|
|
|
caprine.js
|
2022-10-19 20:18:42 +00:00
|
|
|
"
|
2022-10-19 16:15:04 +00:00
|
|
|
|
|
|
|
build() {
|
|
|
|
npm install --ignore-scripts
|
|
|
|
npx --yes patch-package
|
|
|
|
npx tsc
|
|
|
|
rm -r node_modules
|
|
|
|
npm install --ignore-scripts --production
|
|
|
|
npx --yes patch-package
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
local appdir=/usr/lib/$pkgname
|
|
|
|
|
|
|
|
install -d "$pkgdir"$appdir
|
2023-03-31 20:26:25 +00:00
|
|
|
cp -r ./* "$pkgdir"$appdir
|
2022-10-19 16:15:04 +00:00
|
|
|
|
|
|
|
install -dm755 "$pkgdir/usr/share/pixmaps"
|
|
|
|
install -m644 build/icon.png "$pkgdir/usr/share/pixmaps/$pkgname.png"
|
|
|
|
|
|
|
|
install -Dm755 "$srcdir"/$pkgname.js "$pkgdir"/usr/bin/$pkgname
|
|
|
|
install -Dm644 "$srcdir"/$pkgname.desktop \
|
2023-03-31 20:26:25 +00:00
|
|
|
"$pkgdir"/usr/share/applications/$pkgname.desktop
|
2022-10-19 16:15:04 +00:00
|
|
|
|
|
|
|
install -dm755 "$pkgdir"/usr/share/licenses/$pkgname
|
2023-03-31 20:26:25 +00:00
|
|
|
ln -s "$(realpath -m --relative-to=/usr/share/licenses/$pkgname $appdir/license)" \
|
|
|
|
"$pkgdir"/usr/share/licenses/$pkgname
|
2022-10-19 16:15:04 +00:00
|
|
|
|
|
|
|
# Clean up
|
|
|
|
rm -r "$pkgdir"$appdir/build
|
|
|
|
rm -r "$pkgdir"$appdir/source
|
|
|
|
rm -r "$pkgdir"$appdir/tsconfig.json
|
|
|
|
find "$pkgdir"$appdir \
|
|
|
|
-name "package.json" \
|
|
|
|
-exec sed -e "s|$srcdir/$pkgname|$appdir|" \
|
|
|
|
-i {} \; \
|
|
|
|
-or -name ".*" -prune -exec rm -r '{}' \; \
|
|
|
|
-or -name "bin" -prune -exec rm -r '{}' \; \
|
|
|
|
-or -name "example" -prune -exec rm -r '{}' \; \
|
|
|
|
-or -name "examples" -prune -exec rm -r '{}' \; \
|
|
|
|
-or -name "man" -prune -exec rm -r '{}' \; \
|
|
|
|
-or -name "scripts" -prune -exec rm -r '{}' \; \
|
|
|
|
-or -name "test" -prune -exec rm -r '{}' \;
|
|
|
|
}
|
|
|
|
sha512sums="
|
2023-01-11 13:23:51 +00:00
|
|
|
9d019e4aa61f94ffb627f1b647266d28d47c005515d9193ae8a6e67dbac4b4d931ca907dcb2627e4c8eb00e59ab825fc9dd3d9791064cf1cfbd28d8eff4d2589 caprine-2.57.0.tar.gz
|
2022-10-19 20:18:42 +00:00
|
|
|
a469e3bea24926119e51642b777ef794c5fa65421107903f967c36d81bbb1adb3d52469ce3a3301b2c890f1aa53ab989ded22a7c6e811fb8cf0a582dbd835e19 caprine.desktop
|
|
|
|
44280c62ce43bdafa8528729371fccb16b8a0e3db7aca28d5c157ae0144dca5fbb023b8883b561955aa28ab62e967f2674d8c6bcaff186e2cdd0e7ba8beab9ac caprine.js
|
2022-10-19 16:15:04 +00:00
|
|
|
"
|