Compare commits

..

3 Commits

Author SHA1 Message Date
Azure SDK Bot
78de0b7c25
LogGroupStart should have local build output (#6867)
Co-authored-by: Patrick Hallisey <pahallis@microsoft.com>
2025-12-08 23:26:27 -08:00
Azure SDK Bot
884ff2fbab
Sync eng/common directory with azure-sdk-tools for PR 13267 (#6866)
* Updated artifactJson input to artifacts input

* Prioritized service directory from artifact object over the parameter input

* Returned error when service directory is not provided for the old usage

* Removed redudant line

* Initilized the variable in a loop

---------

Co-authored-by: ray chen <raychen@microsoft.com>
2025-12-08 17:37:27 -08:00
dependabot[bot]
a2082c3e5b
Bump github.com/microsoft/vcpkg from master to 2025.10.17 (#6810)
Bumps [github.com/microsoft/vcpkg](https://github.com/microsoft/vcpkg) from master to 2025.10.17. This release includes the previously tagged commit.
- [Release notes](https://github.com/microsoft/vcpkg/releases)
- [Commits](4334d8b4c8...74e6536215)

---
updated-dependencies:
- dependency-name: github.com/microsoft/vcpkg
  dependency-version: 2025.10.17
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-05 13:16:54 -08:00
5 changed files with 76 additions and 44 deletions

View File

@ -5,20 +5,20 @@
Customers with an [Azure support plan](https://azure.microsoft.com/support/options/) can open an [Azure support ticket](https://azure.microsoft.com/support/create-ticket/).
**We recommend this option if your problem requires immediate attention.**
### GitHub issues
### Github issues
We use [GitHub Issues](https://github.com/Azure/azure-sdk-for-cpp/issues/new/choose) to track bugs, questions, and feature requests.
We use [GitHub Issues](https://github.com/Azure/azure-sdk-for-python/issues/new/choose) to track bugs, questions, and feature requests.
GitHub issues are free, but **response time is not guaranteed.** See [GitHub issues support process](https://devblogs.microsoft.com/azure-sdk/github-issue-support-process/) for more details.
To ensure the relevance and manageability of our issue queue, we have an automated process that will close issues that are over two years old and have not been updated in the last 30 days. This measure is designed to help us respond to and resolve current issues more efficiently. We appreciate your understanding and cooperation in maintaining a focused and up-to-date issue tracking system.
### Community resources
- Search for similar issues in [our GitHub repository](https://github.com/Azure/azure-sdk-for-cpp/issues)
- Ask a question on [StackOverflow](https://stackoverflow.com/questions/tagged/azure-sdk-cpp) and tag it with azure-sdk-cpp
- Search for similar issues in [our GitHub repository](https://github.com/Azure/azure-sdk-for-python/issues)
- Ask a question on [StackOverflow](https://stackoverflow.com/questions/tagged/azure-sdk-python) and tag it with azure-sdk-python
- Share or upvote feature requests on [Feedback Page](https://feedback.azure.com/forums/34192--general-feedback).
- Take a look at the [Azure SDK blog](https://devblogs.microsoft.com/azure-sdk/).
- Chat with other community members on [gitter](https://gitter.im/Azure/azure-sdk-for-cpp?source=orgpage)
- Chat with other community members on [gitter](https://gitter.im/Azure/azure-sdk-for-python?source=orgpage)
- Ask a question on [Twitter](https://twitter.com/AzureSDK)
- Ask a question at [Microsoft Q&A](https://learn.microsoft.com/answers/products/azure?WT.mc_id=Portal-Microsoft_Azure_Support&product=all)
- Ask a question at [Microsoft Tech Community](https://techcommunity.microsoft.com/t5/azure/ct-p/Azure)

View File

@ -14,9 +14,9 @@ parameters:
- name: TestPipeline
type: boolean
default: false
- name: ArtifactsJson
type: string
default: ''
- name: Artifacts
type: object
default: []
steps:
- ${{ if eq(parameters.TestPipeline, true) }}:
@ -31,5 +31,5 @@ steps:
-PackageNames '${{ coalesce(parameters.PackageName, parameters.PackageNames) }}'
-ServiceDirectory '${{ parameters.ServiceDirectory }}'
-TagSeparator '${{ parameters.TagSeparator }}'
-ArtifactsJson '${{ parameters.ArtifactsJson }}'
-Artifacts @('${{ replace(convertToJson(parameters.Artifacts), '''', '`''') }}' | ConvertFrom-Json)
pwsh: true

View File

@ -5,63 +5,83 @@ param (
[string]$BuildID,
[Parameter(mandatory = $false)]
[string]$PackageNames = "",
[Parameter(mandatory = $true)]
[Parameter(mandatory = $false)]
# ServiceDirectory is required when using PackageNames,
# or when Artifacts do not include their own ServiceDirectory property.
[string]$ServiceDirectory,
[Parameter(mandatory = $false)]
[string]$TagSeparator = "_",
[Parameter(mandatory = $false)]
[string]$ArtifactsJson = ""
[object[]]$Artifacts = @()
)
. (Join-Path $PSScriptRoot common.ps1)
# Ensure Artifacts is always an array
$Artifacts = @($Artifacts)
Write-Host "PackageNames: $PackageNames"
Write-Host "ServiceDirectory: $ServiceDirectory"
Write-Host "BuildID: $BuildID"
Write-Host "ArtifactsJson: $ArtifactsJson"
Write-Host "Artifacts count: $($Artifacts.Count)"
$packageNamesArray = @()
$artifacts = $null
# If ArtifactsJson is provided, extract package names from it
if (![String]::IsNullOrWhiteSpace($ArtifactsJson)) {
Write-Host "Using ArtifactsJson to determine package names"
if ($Artifacts -and $Artifacts.Count -gt 0) {
# When using Artifacts, process each artifact with its name and groupId (if applicable)
try {
$artifacts = $ArtifactsJson | ConvertFrom-Json
$packageNamesArray = $artifacts | ForEach-Object { $_.name }
Write-Host "Extracted package names from ArtifactsJson: $($packageNamesArray -join ', ')"
}
catch {
LogError "Failed to parse ArtifactsJson: $($_.Exception.Message)"
exit 1
}
}
elseif (![String]::IsNullOrWhiteSpace($PackageNames)) {
$packageNamesArray = $PackageNames.Split(',')
}
else {
LogError "Either PackageNames or ArtifactsJson must be provided."
exit 1
}
foreach ($artifact in $Artifacts) {
# Validate required properties
if (-not (Get-Member -InputObject $artifact -Name 'name' -MemberType Properties)) {
LogError "Artifact is missing required 'name' property."
exit 1
}
if ($artifacts) {
# When using ArtifactsJson, process each artifact with its name and groupId (if applicable)
try {
foreach ($artifact in $artifacts) {
$packageName = $artifact.name
if ([String]::IsNullOrWhiteSpace($packageName)) {
LogError "Artifact 'name' property is null or empty."
exit 1
}
$artifactServiceDirectory = $null
# Check for ServiceDirectory property
if (Get-Member -InputObject $artifact -Name 'ServiceDirectory' -MemberType Properties) {
if (![String]::IsNullOrWhiteSpace($artifact.ServiceDirectory)) {
$artifactServiceDirectory = $artifact.ServiceDirectory
}
}
if ([String]::IsNullOrWhiteSpace($artifactServiceDirectory)) {
$artifactServiceDirectory = $ServiceDirectory
}
# Validate ServiceDirectory is available
if ([String]::IsNullOrWhiteSpace($artifactServiceDirectory)) {
LogError "ServiceDirectory is required but not provided for artifact '$packageName'. Provide it via script parameter or artifact property."
exit 1
}
$newVersion = [AzureEngSemanticVersion]::new("1.0.0")
$prefix = "$packageName$TagSeparator"
if ($Language -eq "java") {
# Check for groupId property
if (-not (Get-Member -InputObject $artifact -Name 'groupId' -MemberType Properties)) {
LogError "Artifact '$packageName' is missing required 'groupId' property for Java language."
exit 1
}
$groupId = $artifact.groupId
Write-Host "Processing $packageName with groupId $groupId"
if ([String]::IsNullOrWhiteSpace($groupId)) {
LogError "GroupId is missing for package $packageName."
exit 1
}
Write-Host "Processing $packageName with groupId $groupId"
# Use groupId+artifactName format for tag prefix (e.g., "com.azure.v2+azure-sdk-template_")
$prefix = "$groupId+$packageName$TagSeparator"
}
else {
Write-Host "Processing $packageName"
}
Write-Host "Get Latest Tag : git tag -l $prefix*"
$latestTags = git tag -l "$prefix*"
@ -87,21 +107,27 @@ if ($artifacts) {
if ($Language -ne "java") {
SetPackageVersion -PackageName $packageName `
-Version $newVersion.ToString() `
-ServiceDirectory $ServiceDirectory
-ServiceDirectory $artifactServiceDirectory
} else {
SetPackageVersion -PackageName $packageName `
-Version $newVersion.ToString() `
-ServiceDirectory $ServiceDirectory `
-ServiceDirectory $artifactServiceDirectory `
-GroupId $groupId
}
}
}
catch {
LogError "Failed to process ArtifactsJson: $ArtifactsJson, exception: $($_.Exception.Message)"
LogError "Failed to process Artifacts: exception: $($_.Exception.Message)"
exit 1
}
} else {
} elseif (![String]::IsNullOrWhiteSpace($PackageNames)) {
# Fallback to original logic when using PackageNames string
if ([String]::IsNullOrWhiteSpace($ServiceDirectory)) {
LogError "ServiceDirectory is required when using PackageNames."
exit 1
}
$packageNamesArray = $PackageNames.Split(',')
foreach ($packageName in $packageNamesArray) {
Write-Host "Processing $packageName"
$newVersion = [AzureEngSemanticVersion]::new("1.0.0")
@ -131,4 +157,7 @@ if ($artifacts) {
-Version $newVersion.ToString() `
-ServiceDirectory $ServiceDirectory
}
} else {
LogError "Either PackageNames or Artifacts must be provided."
exit 1
}

View File

@ -94,6 +94,9 @@ function LogGroupStart() {
elseif (Test-SupportsGitHubLogging) {
Write-Host "::group::$args"
}
else {
Write-Host "> $args"
}
}
function LogGroupEnd() {

View File

@ -1,7 +1,7 @@
{
"name": "azure-sdk-for-cpp",
"version": "1.5.0",
"builtin-baseline": "4334d8b4c8916018600212ab4dd4bbdc343065d1",
"builtin-baseline": "74e6536215718009aae747d86d84b78376bf9e09",
"dependencies": [
{
"name": "curl"