Skip to content

Commit

Permalink
Merge pull request #725 from aaronparker/development
Browse files Browse the repository at this point in the history
Update Get-EvergreenLibrary.ps1
  • Loading branch information
aaronparker authored Jul 30, 2024
2 parents edb80e5 + c112a17 commit ef04610
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Evergreen/Public/Get-EvergreenLibrary.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,19 @@ function Get-EvergreenLibrary {
$true
}
else {
throw "'$_' must be in the format 'https://<storageaccount>/<container>/EvergreenLibrary.json'."
throw "'$_' must be in the format 'https://<storageaccount>/<container>/EvergreenLibrary.json' or 'https://<storageaccount>/<container>/Library.json'."
}
})]
[System.Uri] $Uri
)

begin {
if ($PSBoundParameters.ContainsKey("Uri")) {
# Get the details from the library
$Library = Invoke-EvergreenRestMethod -Uri $Uri
$ParentUri = Split-Path -Path $Uri -Parent

# Get the parent URI which we will use later
$ParentUri = ($Uri.ToString() -replace $Uri.Segments[-1], "").Trim("/")

# Build the output object
$Output = [PSCustomObject] @{
Expand Down

0 comments on commit ef04610

Please sign in to comment.