删除应用程序后为什么会留下日志? [英] Why are logs left after removal of an application has occurred?

查看:81
本文介绍了删除应用程序后为什么会留下日志?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好。

我正在努力解决wix工具集的问题:为什么在我卸载应用程序后,包括日志在内的一些文件夹不会被删除?这是一个bug还是没有?



Hello to everyone.
I am struggling against the issue with wix toolset: why after I uninstall an application some folders including the "logs" are not deleted? is it a bug or not?

<Directory Id="logs" Name="logs">
<Component Id="logs" Guid="0A4D0A3F-2E0D-1B1A-1C6D-1A0F8FAAABC6" Win64="$(var.is64)">
      <CreateFolder Directory="logs">
       <Permission GenericAll="yes" User="Everyone" />
       </CreateFolder>
       <RemoveFolder Id="logs"  On="uninstall"></RemoveFolder>
       </Component>
       </Directory>

推荐答案

(var.is64)>
< CreateFolder Directory = logs>
< Permission GenericAll =yesUser =Everyone/>
< / CreateFolder>
< RemoveFolder Id =logsOn =uninstall >< / RemoveFolder>
< / Component>
< /目录>
(var.is64)"> <CreateFolder Directory="logs"> <Permission GenericAll="yes" User="Everyone" /> </CreateFolder> <RemoveFolder Id="logs" On="uninstall"></RemoveFolder> </Component> </Directory>


这不是错误。



您告诉它删除文件夹,该文件夹始终假定文件夹为空。如果文件夹不为空,则不会被删除。



由于您的安装程序不知道日志文件(它没有将它们放在那里!)它无法在没有自定义操作的情况下删除它们。在自定义操作中删除文件文件夹被删除,它将工作。
It's not a bug.

You told it to delete the folder, which always assumes the folder is empty. If the folder is not empty it doesn't get deleted.

Since your installer doesn't know about the log files (it didn't put them there!) it can't delete them without a custom action. Delete the files in a custom action before the folders are deleted and it'll work.


这篇关于删除应用程序后为什么会留下日志?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆