# Maintainer: zxp19821005 pkgname="p3x-onenote-appimage" pkgver=2023.4.119 pkgrel=1 pkgdesc="Linux Electron Onenote - A Linux compatible version of OneNote" arch=("aarch64" "armv7h" "x86_64") url="https://www.corifeus.com/onenote/" _githuburl="https://github.com/patrikx3/onenote" license=('MIT') depends=('hicolor-icon-theme' 'zlib' 'glibc') options=(!strip) conflicts=("${pkgname%-appimage}") _install_path="/opt/appimages" source_aarch64=("${pkgname%-appimage}-${pkgver}-aarch64.AppImage::${_githuburl}/releases/download/v${pkgver}/P3X-OneNote-${pkgver}-arm64.AppImage") source_armv7h=("${pkgname%-appimage}-${pkgver}-armv7h.AppImage::${_githuburl}/releases/download/v${pkgver}/P3X-OneNote-${pkgver}-armv7l.AppImage") source_x86_64=("${pkgname%-appimage}-${pkgver}-x86_64.AppImage::${_githuburl}/releases/download/v${pkgver}/P3X-OneNote-${pkgver}.AppImage") source=("LICENSE::https://raw.githubusercontent.com/patrikx3/onenote/master/LICENSE") sha256sums=('0bf4779e41d65d73a0f808a16dabc4d9fe88dcb23044e67d2c146b72c15ae5d9') sha256sums_aarch64=('f7e4707d7fb86b344067dc444b5f8c4c40bcee06ff8ff0f863730018d56f0ed7') sha256sums_armv7h=('09c2814297f29cb8efc8e28e05d628d0017aab8719085774295e76d6de378c9a') sha256sums_x86_64=('ecb9ba2f2328d77ebf7ea19f3e08ded7ad8d39b9fa28738c2149d871f15f8c7e') prepare() { chmod a+x "${srcdir}/${pkgname%-appimage}-${pkgver}-${CARCH}.AppImage" "${srcdir}/${pkgname%-appimage}-${pkgver}-${CARCH}.AppImage" --appimage-extract > /dev/null sed "s|AppRun|${_install_path}/${pkgname%-appimage}.AppImage|g" -i "${srcdir}/squashfs-root/${pkgname%-appimage}.desktop" } package() { install -Dm755 "${srcdir}/${pkgname%-appimage}-${pkgver}-${CARCH}.AppImage" "${pkgdir}/${_install_path}/${pkgname%-appimage}.AppImage" install -Dm644 "${srcdir}/squashfs-root/${pkgname%-appimage}.desktop" "${pkgdir}/usr/share/applications/${pkgname%-appimage}.desktop" for _icons in 128x128 256x256;do install -Dm644 "${srcdir}/squashfs-root/usr/share/icons/hicolor/${_icons}/apps/${pkgname%-appimage}.png" \ -t "${pkgdir}/usr/share/icons/hicolor/${_icons}/apps" done install -Dm644 "${srcdir}/LICENSE" -t "${pkgdir}/usr/share/licenses/${pkgname}" }