forked from openkylin/kylin-code
更改软件名称后,修改卸载时删除插件目录和软件用户数据目录的名称,本次修改为product.json中配置的值.
This commit is contained in:
parent
5773404e72
commit
09f0f9a241
|
@ -91,6 +91,8 @@ function prepareDebPackage(arch) {
|
|||
|
||||
const postrm = gulp.src('resources/linux/debian/postrm.template', { base: '.' })
|
||||
.pipe(replace('@@NAME@@', product.applicationName))
|
||||
.pipe(replace('@@NAME_LONG@@', product.nameLong))
|
||||
.pipe(replace('@@DATA_FOLDER@@', product.dataFolderName))
|
||||
.pipe(rename('DEBIAN/postrm'));
|
||||
|
||||
const postinst = gulp.src('resources/linux/debian/postinst.template', { base: '.' })
|
||||
|
@ -180,6 +182,7 @@ function prepareRpmPackage(arch) {
|
|||
const spec = gulp.src('resources/linux/rpm/code.spec.template', { base: '.' })
|
||||
.pipe(replace('@@NAME@@', product.applicationName))
|
||||
.pipe(replace('@@NAME_LONG@@', product.nameLong))
|
||||
.pipe(replace('@@DATA_FOLDER@@', product.dataFolderName))
|
||||
.pipe(replace('@@ICON@@', product.linuxIconName))
|
||||
.pipe(replace('@@VERSION@@', packageJson.IDEVersion))
|
||||
.pipe(replace('@@RELEASE@@', linuxPackageRevision))
|
||||
|
|
|
@ -12,7 +12,7 @@ fi
|
|||
|
||||
case "$1" in
|
||||
purge|P)
|
||||
rm -rf /home/${SUDO_USER}/.config/Code\ -\ OSS
|
||||
rm -rf /home/${SUDO_USER}/.vscode-oss
|
||||
rm -rf /home/${SUDO_USER}/.config/@@NAME_LONG@@
|
||||
rm -rf /home/${SUDO_USER}/@@DATA_FOLDER@@
|
||||
;;
|
||||
esac
|
||||
|
|
|
@ -58,8 +58,8 @@ update-mime-database /usr/share/mime &> /dev/null || :
|
|||
%postun
|
||||
if [ $1 = 0 ]; then
|
||||
rm -f /usr/bin/@@NAME@@
|
||||
rm -rf /home/${SUDO_USER}/.config/Code\ -\ OSS
|
||||
rm -rf /home/${SUDO_USER}/.vscode-oss
|
||||
rm -rf /home/${SUDO_USER}/.config/@@NAME_LONG@@
|
||||
rm -rf /home/${SUDO_USER}/@@DATA_FOLDER@@
|
||||
fi
|
||||
|
||||
# Update mimetype database for removed workspace mimetype
|
||||
|
|
Loading…
Reference in New Issue