我想准备好 package.config 文件,以便下次将 Win7 恢复到我的上网本时使用。
我的大多数软件包都属于 chocolatey 软件组,但有些不在。因此,我下载了非 chocolatey 软件,并准备了以下测试配置文件,以查看 chocolatey 是否可以在本地驱动器上批量安装 *.exe 程序:
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="clipx-1.0.3.8-setup.exe" source="D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-1.0.3.8-setup.exe" />
<package id="clipx-autoupdate-1.6-x86.exe" source="D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-autoupdate-1.6-x86.exe" />
<package id="clipx-disklog-1.2-x86.exe" source="D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-disklog-1.2-x86.exe" />
<package id="clipx-limits-1.2-x86.exe" source="D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-limits-1.2-x86.exe" />
<package id="clipx-stickies-1.9-x86.exe" source="D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-stickies-1.9-x86.exe" />
</packages>
我也尝试了上述不带路径 *.exe 部分的操作,但无论什么 chocolatey 都无法安装,报告说所有 5 个程序都无法安装,更具体地说:
Error serializing type chocolatey.infrastructure.app.configuration.ConfigFileSettings:
Access to the path 'C:\ProgramData\chocolatey\config\chocolatey.config' is denied.
Error updating 'C:\ProgramData\chocolatey\config\chocolatey.config'. Please ensure you have permissions to do so:
Access to the path 'C:\ProgramData\chocolatey\config\chocolatey.config' is denied.
Chocolatey v0.9.9.4
Installing the following packages:
packages0426.config
By installing you accept licenses for the packages.
clipx-1.0.3.8-setup.exe not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-1.0.3.8-setup.exe"
clipx-autoupdate-1.6-x86.exe not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-autoupdate-1.6-x86.exe"
clipx-disklog-1.2-x86.exe not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-disklog-1.2-x86.exe"
clipx-limits-1.2-x86.exe not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-limits-1.2-x86.exe"
clipx-stickies-1.9-x86.exe not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "D:\AC\bckup\Install\3_Windows\04_PROGRAM_INSTALL_Manual\ClipX\clipx-stickies-1.9-x86.exe"
Chocolatey installed 0/5 package(s). 5 package(s) failed.
See the log for details.
Failures:
- clipx-1.0.3.8-setup.exe
- clipx-stickies-1.9-x86.exe
- clipx-disklog-1.2-x86.exe
- clipx-autoupdate-1.6-x86.exe
- clipx-limits-1.2-x86.exe
是的,我确实是从以管理员身份打开的 cmd 中执行此操作的。
chocolatey 可以在本地安装 *.exe 程序吗?
安德鲁
答案1
回答你的问题,是的,Chocolatey 可以*.exe
在本地安装程序,但是你仍然需要一个指向那些本地原生安装程序(*.exe
文件)的 Chocolatey 包。
Chocolatey 可以安装直接地从本机安装程序,但仅使用直接安装程序(在 Chocolatey for Business 中可用)。
.nupkg
因此,您仍然需要包含指向本地安装程序(例如)的安装说明的软件包(又名文件) setup.exe
。