summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorssfdust2017-10-13 10:58:22 +0800
committerssfdust2017-10-13 10:58:22 +0800
commitd3c602e52782cac945daf70dcdd1d31b841aae8b (patch)
tree72a8ee9ad1a72a4838c8989f3ecffc082e1cb7fd
parent0583aacb9d4db2cff45efb1af340bf17c624c24b (diff)
downloadaur-d3c602e52782cac945daf70dcdd1d31b841aae8b.tar.gz
add install file
-rw-r--r--PKGBUILD1
-rw-r--r--deepin-tim-for-arch.install12
2 files changed, 13 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 39bf94f5a6e0..64975bcb20a9 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -11,6 +11,7 @@ url="http://tim.qq.com/"
license=('custom')
depends=('p7zip' 'wine' 'xorg-xwininfo' 'xdotool' 'wqy-microhei')
conflicts=('wine-tim')
+install="deepin-tim-for-arch.install"
_mirror="https://mirrors.ustc.edu.cn/deepin"
source=("$_mirror/pool/non-free/d/deepin.com.qq.office/deepin.com.qq.office_${deepintimver}_i386.deb"
"http://dldir1.qq.com/qqfile/qq/TIM${pkgver}/21175/TIM${pkgver}.exe"
diff --git a/deepin-tim-for-arch.install b/deepin-tim-for-arch.install
new file mode 100644
index 000000000000..9bfc53ff1766
--- /dev/null
+++ b/deepin-tim-for-arch.install
@@ -0,0 +1,12 @@
+post_install() {
+ sed "s/\(Categories.*$\)/\1Network;/" -i /usr/share/applications/deepin.com.qq.office.desktop
+}
+
+post_upgrade() {
+ new_tim_version=$(echo $1 | sed "s/-.*//")
+ find /home -maxdepth 2 -name ".deepinwine" -exec sed -i "s/.*/$new_tim_version/" \{\}/Deepin-TIM/PACKAGE_VERSION \;
+}
+
+pre_remove() {
+ find /home -maxdepth 2 -name ".deepinwine" -exec rm -rf \{\} \;
+}