How load the PowerShell App-V 5 cmdlets and help.
1. To load the PowerShell App-V 5 cmdlet modules:
Open a Windows PowerShell prompt or launch the Windows PowerShell Integrated Scripting Environment (ISE).
Type one of the following commands to load the cmdlets for the module you want:
App-V component | Command |
App-V Server | Import-Module AppvServer |
App-V Sequencer | Import-Module AppvSequencer |
App-V Client |
Import-Module AppvClient |
2. To load up the PowerShell App-V 5 help modules:
App-V component | Command |
App-V Server | Update-Help -Module AppvServer |
App-V Sequencer | Update-Help -Module AppvSequencer |
App-V Client | Update-Help -Module AppvClient |
Type Get-Help <cmdlet> to display help for a specific PowerShell cmdlet, for example:
get-help Mount-AppvClientPackage
NAME
Mount-AppvClientPackage
SYNOPSIS
Loads a package into the App-V cache.
SYNTAX
Mount-AppvClientPackage [-PackageId] <Guid> [-VersionId] <Guid> [-Cancel] [<CommonParameters>]
Mount-AppvClientPackage [-Package] <AppvClientPackage> [-Cancel] [<CommonParameters>]
Mount-AppvClientPackage [-Name] <String> [[-Version] [<String>]] [<CommonParameters>]
DESCRIPTION
The Mount-AppvClientPackage cmdlet initiates or resumes the loading of an Microsoft Application Virtualization (App-V) package into the cache.
Example 2:
get-help Mount-AppvClientPackage -examples
NAME
Mount-AppvClientPackage
SYNOPSIS
Loads a package into the App-V cache.
Example 1: Get a specific version of a package
PS C:\> Mount-AppvClientPackage -Name "MyApp" -Version 2
This command downloads the version 2 of the package named MyApp.
Example 2: Get all versions of a package
PS C:\> Mount-AppvClientPackage -Name "MyApp"
This command downloads the all versions of the package named MyApp.
Example 3: Download all packages that match a string
PS C:\> Get-AppvClientPackage -Name "My*" | Mount-AppvClientPackage
This command gets all packages that have the string My in the name, and then download them.
Example 4: Download and publish a new package
PS C:\> Add-AppvClientPackage -Path "http://MyServer/content/package.Appv" | Mount-AppvClientPackage | Publish-AppvClientPackage -Global
This command adds the package from the path specified, then downloads it, and then publishes it to all users on the computer.
Example 5: Cancel a download
PS C:\> Mount-AppvClientPackage -Name "MyApp" -Cancel
This command cancels the download of the package name MyApp.