# Maintainer: vvxxp8 pkgname=siyuan-appimage pkgver=2.3.2 pkgrel=1 pkgdesc="A local-first personal knowledge management system, support fine-grained block-level reference and Markdown WYSIWYG" arch=("x86_64") url="https://b3log.org/siyuan" license=("AGPL3") _pkgname="siyuan-${pkgver}-linux.AppImage" noextract=(${_pkgname}) options=("!strip") provides=("siyuan") optdepends=('pandoc: docx export') source=("https://release.b3log.org/siyuan/${_pkgname}") sha512sums=("c990ffd3c5f95ed3dc6ac6d44880e1dd04fb51b7833740e16ea8a5f0f1bf1d8393162f3c5edc7c19a72250221d35bc46bb4cfe25e9445fd6355037df32d87c76") _installdir=/opt/appimages prepare() { cd ${srcdir} chmod a+x ${_pkgname} ${srcdir}/${_pkgname} --appimage-extract >/dev/null sed -i "s+AppRun+env DESKTOPINTEGRATION=no ${_installdir}/siyuan.AppImage+" "squashfs-root/siyuan.desktop" sed -i "s+Icon=siyuan+Icon=siyuan-appimage+" "squashfs-root/siyuan.desktop" } package() { install -Dm755 ${_pkgname} "${pkgdir}/${_installdir}/siyuan.AppImage" install -Dm644 "squashfs-root/resources/stage/icon.png" "${pkgdir}/usr/share/icons/hicolor/512x512/apps/siyuan-appimage.png" install -Dm644 "squashfs-root/siyuan.desktop" "${pkgdir}/usr/share/applications/siyuan-appimage.desktop" }