PS /home/manikb> gmo
ModuleType Version Name ExportedCommands
---------- ------- ---- ----------------
Manifest 3.1.0.0 Microsoft.PowerShell.Utility {Add-Member, Add-Type, Clear-Variable, Compare-Object...}
Script 1.2 PSReadLine {Get-PSReadlineKeyHandler, Get-PSReadlineOption, Remove-PS...
PS /home/manikb> Get-PSRepository
Name InstallationPolicy SourceLocation
---- ------------------ --------------
INT Trusted https://dtlgalleryint.cloudapp.net/api/v2/
PSGallery Untrusted https://www.powershellgallery.com/api/v2/
PS /home/manikb> Get-InstalledModule
PS /home/manikb> install-module contososerver -repo int -verbose -scope CurrentUser
VERBOSE: Repository details, Name = 'INT', Location = 'https://dtlgalleryint.cloudapp.net/api/v2/'; IsTrusted = 'True';
IsRegistered = 'True'.
VERBOSE: Using the provider 'PowerShellGet' for searching packages.
VERBOSE: Using the specified source names : 'int'.
VERBOSE: Getting the provider object for the PackageManagement Provider 'NuGet'.
VERBOSE: The specified Location is 'https://dtlgalleryint.cloudapp.net/api/v2/' and PackageManagementProvider is
'NuGet'.
VERBOSE: Searching repository 'https://dtlgalleryint.cloudapp.net/api/v2/FindPackagesById()?id='contososerver'' for ''.
VERBOSE: Total package yield:'1' for the specified package 'contososerver'.
VERBOSE: Performing the operation "Install-Module" on target "Version '2.5' of module 'ContosoServer'".
VERBOSE: The installation scope is specified to be 'CurrentUser'.
VERBOSE: The specified module will be installed in '/home/manikb/.local/share/powershell/Modules'.
VERBOSE: The specified Location is 'NuGet' and PackageManagementProvider is 'NuGet'.
VERBOSE: Downloading module 'ContosoServer' with version '2.5' from the repository
'https://dtlgalleryint.cloudapp.net/api/v2/'.
VERBOSE: Searching repository 'https://dtlgalleryint.cloudapp.net/api/v2/FindPackagesById()?id='ContosoServer'' for ''.
VERBOSE: InstallPackage' - name='ContosoServer', version='2.5',destination='/tmp/1358711381'VERBOSE: DownloadPackage' - name='ContosoServer',
version='2.5',destination='/tmp/1358711381/ContosoServer/ContosoServer.nupkg',
uri='https://dtlgalleryint.cloudapp.net/api/v2/package/ContosoServer/2.5.0'VERBOSE: Downloading 'https://dtlgalleryint.cloudapp.net/api/v2/package/ContosoServer/2.5.0'.VERBOSE: Completed downloading 'https://dtlgalleryint.cloudapp.net/api/v2/package/ContosoServer/2.5.0'.VERBOSE: Completed downloading 'ContosoServer'.VERBOSE: InstallPackageLocal' - name='ContosoServer', version='2.5',destination='/tmp/1358711381'VERBOSE: Module 'ContosoServer' was installed successfully to path
'/home/manikb/.local/share/powershell/Modules/ContosoServer/2.5'.
VERBOSE: The module 'Microsoft.PowerShell.Diagnostics' could not be loaded. For more information, run 'Import-Module
Microsoft.PowerShell.Diagnostics'.
PS /home/manikb> Get-InstalledModule
Version Name Repository Description
------- ---- ---------- -----------
2.5 ContosoServer INT ContosoServer module
PS /home/manikb> Get-InstalledModule | Uninstall-Module -Verbose -Debug
DEBUG: 00:00:00.0000014 Calling New() : MethodName = 'GetDynamicOptions'
Confirm
Continue with this operation?
[Y] Yes [A] Yes to All [H] Halt Command [S] Suspend [?] Help (default is "Y"): A
DEBUG: 00:00:00.0002391 Name: ContosoServer
DEBUG: 00:00:00.0003813 Debug: True
DEBUG: 00:00:00.0005024 RequiredVersion: 2.5
DEBUG: 00:00:00.0006247 Verbose: True
DEBUG: 00:00:00.0042243 INVOKING PowerShell Fn Get-DynamicOptions with args Provider that has length 1
DEBUG: 00:00:00.0080331 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0136877 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0267236 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0269121 Name: ContosoServer
DEBUG: 00:00:00.0270358 Debug: True
DEBUG: 00:00:00.0272014 RequiredVersion: 2.5
DEBUG: 00:00:00.0273271 Verbose: True
DEBUG: 00:00:00.0308418 INVOKING PowerShell Fn Get-DynamicOptions with args Install that has length 1
DEBUG: 00:00:00.0340494 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0663571 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:01.5838931 Calling New() : MethodName = 'GetInstalledPackages'
DEBUG: 00:00:01.5854818 Debug: True
DEBUG: 00:00:01.5869118 RequiredVersion: 2.5
DEBUG: 00:00:01.5883265 MessageResolver: Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:01.5897477 ProviderName: PowerShellGet
DEBUG: 00:00:01.5971416 Type: Module
DEBUG: 00:00:01.5985471 Name: ContosoServer
DEBUG: 00:00:01.6000207 Verbose: True
DEBUG: 00:00:01.6091936 INVOKING PowerShell Fn Get-InstalledPackage with args ContosoServer, 2.5, , that has length 4
DEBUG: 00:00:01.6148168 In PowerShellGet Provider - 'Get-InstalledPackage'.
DEBUG: 00:00:01.6333785 OPTION: Debug => True
DEBUG: 00:00:01.6356021 OPTION: RequiredVersion => 2.5
DEBUG: 00:00:01.6410851 OPTION: MessageResolver => Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:01.6429382 OPTION: ProviderName => PowerShellGet
DEBUG: 00:00:01.6479064 OPTION: Type => Module
DEBUG: 00:00:01.6654882 OPTION: Name => ContosoServer
DEBUG: 00:00:01.6864067 OPTION: Verbose => True
DEBUG: 00:00:01.8989605 Done calling powershell «Get-InstalledPackage» «PSModule»
DEBUG: 00:00:01.9653134 Uninstalling package ContosoServer with provider PowerShellGet
Confirm
Are you sure you want to perform this action?
Performing the operation "Uninstall-Module" on target "Version '2.5' of module 'ContosoServer'".
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"): A
DEBUG: 00:00:03.2662674 Calling New() : MethodName = 'UninstallPackage'
DEBUG: 00:00:03.2776318 Debug: True
DEBUG: 00:00:03.2790507 RequiredVersion: 2.5
DEBUG: 00:00:03.2804257 MessageResolver: Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:03.2849838 ProviderName: PowerShellGet
DEBUG: 00:00:03.2862994 Type: Module
DEBUG: 00:00:03.2875507 Name: ContosoServer
DEBUG: 00:00:03.2935281 Verbose: True
DEBUG: 00:00:03.3042908 INVOKING PowerShell Fn Uninstall-Package with args
NuGet|ContosoServer|2.5|https://dtlgalleryint.cloudapp.net/api/v2/|Module that has length 1
DEBUG: 00:00:03.4256505 In PowerShellGet Provider - 'Uninstall-Package'.
DEBUG: 00:00:03.4364016 The FastPackageReference is
'NuGet|ContosoServer|2.5|https://dtlgalleryint.cloudapp.net/api/v2/|Module'.
DEBUG: 00:00:03.4451097 OPTION: Debug => True
DEBUG: 00:00:03.4599739 OPTION: RequiredVersion => 2.5
DEBUG: 00:00:03.4789817 OPTION: MessageResolver => Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:03.4832408 OPTION: ProviderName => PowerShellGet
DEBUG: 00:00:03.4890636 OPTION: Type => Module
DEBUG: 00:00:03.4999688 OPTION: Name => ContosoServer
DEBUG: 00:00:03.5052394 OPTION: Verbose => True
VERBOSE: Successfully uninstalled the module 'ContosoServer' from module base
'/home/manikb/.local/share/powershell/Modules/ContosoServer/2.5'.
Confirm
An error has occurred which Windows PowerShell cannot handle. A remote session might have ended.
[Y] Yes [A] Yes to All [H] Halt Command [S] Suspend [?] Help (default is "Y"): A
PackageManagement\Uninstall-Package : An error has occurred which Windows PowerShell cannot handle. A remote session might have ended.
At /home/manikb/Documents/PowerShell/src/powershell/bin/Linux/netcoreapp1.0/ubuntu.14.04-x64/Modules/PowerShellGet/PSMo
dule.psm1:2054 char:25
+ ... $null = PackageManagement\Uninstall-Package @PSBoundParameters
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OpenError: (localhost:String) [Uninstall-Package], Exception
+ FullyQualifiedErrorId : PSSessionStateBroken,Microsoft.PowerShell.PackageManagement.Cmdlets.UninstallPackage
PS /home/manikb> $PSVersionTable
Name Value
---- -----
PSVersion 5.1.10032.0
PSEdition Linux
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 3.0.0.0
GitCommitId v0.6.0-48-g1dc0b9a813982802e31bccc6478e238ed72bd910
CLRVersion
WSManStackVersion 1.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
PS /home/manikb> $Error | fl * -Force
writeErrorStream : True
PSMessageDetails :
Exception : System.Exception: An error has occurred which Windows PowerShell cannot handle. A remote
session might have ended.
TargetObject : localhost
CategoryInfo : OpenError: (localhost:String) [Uninstall-Package], Exception
FullyQualifiedErrorId : PSSessionStateBroken,Microsoft.PowerShell.PackageManagement.Cmdlets.UninstallPackage
ErrorDetails :
InvocationInfo : System.Management.Automation.InvocationInfo
ScriptStackTrace : at Uninstall-Module<Process>, /home/manikb/Documents/PowerShell/src/powershell/bin/Linux/netcor
eapp1.0/ubuntu.14.04-x64/Modules/PowerShellGet/PSModule.psm1: line 2074
at <ScriptBlock>, <No file>: line 1
PipelineIterationInfo : {0, 1}