python - 有没有办法可以使用 Python 删除所有 Windows 的还原点?
问题描述
每次我卸载软件(Revo Uninstaller Pro)时,都会创建一个新的 Windows 还原点,我想创建一个简单的脚本,我将把它放在我的桌面上,每次点击它,我的 Windows 的还原点将被删除,但我不想完全禁用它,因为这很重要。
我问过谷歌,但我没有用 Python 找到任何关于它的信息。
有没有办法可以删除所有 Windows 的还原点?
解决方案
你不能直接用 python 做到这一点。您需要运行执行此操作的 power shell 脚本并从 python 调用它。
Microsoft 已经为您编写了 power shell 脚本:https ://gallery.technet.microsoft.com/scriptcenter/Script-to-delete-System-4960775a
如何从python调用 powershell脚本在python脚本中运行powershell脚本,如何让python在运行时打印powershell输出
推荐阅读
- javascript - 无法通过 AJAX 请求捕获来自服务器的响应
- flutter - 如何在 Flutter 中将相机图像转换为图像?
- python - 如何在 Python 中记录第三方导入模块错误
- javascript - 当我从使用服务获取的数组中删除一个元素时,它在哪里被删除?
- python - 当python中的毫秒为零时如何将时间戳写入txt文件
- windows-10-iot-core - 如何在 Windows IoT 核心设备中为特定时间安排任务
- sql-server - 内连接事务和帐户非常慢
- http - 关于使用 netty 关闭简单 http 服务器的空闲连接的问题
- r - 基于连续字符串的动态回复
- sonarqube - 7.9.1x 不作为服务启动 - 引发启动限制命中错误