更新配置文件

添加autorelease.sh文件
增加预安装脚本
This commit is contained in:
liuxueli
2019-12-12 15:38:14 +08:00
parent 7282a23e29
commit 68bc2cea5b
9 changed files with 164 additions and 106 deletions

14
preinstall/install.sh Normal file
View File

@@ -0,0 +1,14 @@
#!/bin/sh
DST=${RPM_INSTALL_PREFIX}
mkdir -p ${DST}/plug/platform/
mkdir -p ${DST}/etc/
touch ${DST}/plug/conflist.inf
touch ${DST}/etc/project_list.conf
if [[ -z `grep -rn 'POLICY_PRIORITY' ${DST}/etc/project_list.conf` ]];then
echo 'POLICY_PRIORITY struct' >> ${DST}/etc/project_list.conf
fi
if [[ -z `grep -rn 'tsg_master.inf' ${DST}/plug/conflist.inf` ]];then
sed -i '/\[platform\]/a\./plug/platform/tsg_master/tsg_master.inf' ${DST}/plug/conflist.inf
fi

5
preinstall/uninstall.sh Normal file
View File

@@ -0,0 +1,5 @@
#!/bin/sh
DST=${RPM_INSTALL_PREFIX}
mkdir -p ${DST}/plug/platform/
sed -i '/tsg_master.inf/d' ${DST}/plug/conflist.inf
sed -i '/POLICY_PRIORITY/d' ${DST}/etc/project_list.conf