NetApp-StorageGRID / StorageGRID-PowerShell-Module

StorageGRID S3 Management PowerShell Cmdlets
MIT License
0 stars 0 forks source link

Alias like "Sort" or "Select" not working on mac os #1

Closed szawacki closed 7 years ago

szawacki commented 7 years ago

Alias are not working on mac os. Running the cmdlet "Connect-SGWServer -Name $servername -Credential $credential -Insecure" produces the following error.

Sort : The term 'Sort' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if 
a path was included, verify that the path is correct and try again.
At /usr/local/microsoft/powershell/6.0.0-beta.2/Modules/StorageGRID-Webscale/4.0.1/StorageGRID-Webscale.psm1:159 char:59
+ ...    $APIVersion = (Get-SGWVersions -Uri "https://$Name" | Sort | selec ...

    + CategoryInfo          : ObjectNotFound: (Sort:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

This is a known issue, see: https://github.com/PowerShell/vscode-powershell/issues/714 Replacing with the long form sort-object or select-object should fix the problem.

Version information:

Name                           Value                                                                                                                 
----                           -----                                                                                                                 
PSVersion                      6.0.0-beta                                                                                                            
PSEdition                      Core                                                                                                                  
BuildVersion                   3.0.0.0                                                                                                               
CLRVersion                                                                                                                                           
GitCommitId                    v6.0.0-beta.2                                                                                                         
OS                             Darwin 16.6.0 Darwin Kernel Version 16.6.0: Fri Apr 14 16:21:16 PDT 2017; root:xnu-3789.60.24~6/RELEASE_X86_64        
Platform                       Unix                                                                                                                  
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}                                                                                               
PSRemotingProtocolVersion      2.3                                                                                                                   
SerializationVersion           1.1.0.1                                                                                                               
WSManStackVersion              3.0