コード例 #1
0
 /// <summary>
 /// Installs MSI package on remote server using the URI to the MSI package. 
 /// ConDep will first download the MSI package to the server and then install the package.
 /// </summary>
 /// <param name="install"></param>
 /// <param name="packageName">A uniqe package name (DisplayName in Windows Registry) to make this 
 /// operation idempotent. If this package name is not correct, ConDep will install this package 
 /// on every execution. ConDep looks in these three registry keys for installed software packages: 
 /// HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall
 /// HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall
 /// HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall</param>
 /// <param name="srcMsiUri">A URI to the MSI package</param>
 /// <returns></returns>
 public static IOfferRemoteInstallation Msi(this IOfferRemoteInstallation install, string packageName, Uri srcMsiUri)
 {
     var msiOperation = new MsiOperation(packageName, srcMsiUri);
     Configure.Operation(install, msiOperation);
     return install;
 }
コード例 #2
0
 /// <summary>
 /// Installs MSI package on remote server using the URI to the MSI package. 
 /// ConDep will first download the MSI package to the server and then install the package.
 /// </summary>
 /// <param name="install"></param>
 /// <param name="packageName">A uniqe package name (DisplayName in Windows Registry) to make this 
 /// operation idempotent. If this package name is not correct, ConDep will install this package 
 /// on every execution. ConDep looks in these three registry keys for installed software packages: 
 /// HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall
 /// HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall
 /// HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall</param>
 /// <param name="srcMsiUri">A URI to the MSI package</param>
 /// <param name="options">Additional options to pass in to msiexec.</param>
 /// <returns></returns>
 public static IOfferRemoteInstallation Msi(this IOfferRemoteInstallation install, string packageName, Uri srcMsiUri, Action<IOfferInstallOptions> options)
 {
     var msiOptions = new InstallOptions();
     options(msiOptions);
     var msiOperation = new MsiOperation(packageName, srcMsiUri, msiOptions.Values);
     Configure.Operation(install, msiOperation);
     return install;
 }