summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: b47bfc5349d58fe34283c3a7a78e5852006cd2d4 (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
# Maintainer: Jack Chen <redchenjs@live.com>

pkgname=mitalk
pkgver=4.0.19
pkgrel=1
pkgdesc="MiTalk Messenger"
arch=('x86_64')
url="http://www.miliao.com/"
license=('custom')
makedepends=(
    'p7zip'
    'sed'
)
source=(
    'mitalk.appimage::https://s1.zb.mi.com/miliao/apk/miliao/7.4/MiTalk_4.0.19.AppImage'
)
md5sums=(
    'b6d92c52d2c0f27e55a07b5f1255669e'
)

package() {
    7z x mitalk.appimage -o"${pkgdir}"/opt/mitalk/

    chmod -R 755 "${pkgdir}"/opt/

    mkdir -p "${pkgdir}"/usr/
    mv "${pkgdir}"/opt/mitalk/usr/share/ "${pkgdir}"/usr/

    sed -i "s/Exec=AppRun/Exec=\/opt\/mitalk\/AppRun/g" "${pkgdir}"/opt/mitalk/mitalk.desktop
    install -Dm644 "${pkgdir}"/opt/mitalk/mitalk.desktop "${pkgdir}"/usr/share/applications/mitalk.desktop

    rm "${pkgdir}"/opt/mitalk/mitalk.png
    rm "${pkgdir}"/opt/mitalk/mitalk.desktop
}