59 lines
2.1 KiB
YAML
59 lines
2.1 KiB
YAML
# Called by ci.yml to perform package validation
|
|
# See: https://docs.github.com/en/actions/using-workflows/reusing-workflows#creating-a-reusable-workflow
|
|
name: Package Validation
|
|
|
|
on:
|
|
workflow_call:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
run-package-validation-stable:
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
|
with:
|
|
# Note: By default GitHub only fetches 1 commit. MinVer needs to find
|
|
# the version tag which is typically NOT on the first commit so we
|
|
# retrieve them all.
|
|
fetch-depth: 0
|
|
|
|
- name: Setup dotnet
|
|
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1
|
|
|
|
- name: dotnet pack
|
|
run: dotnet pack ./build/OpenTelemetry.proj --configuration Release /p:EnablePackageValidation=true /p:ExposeExperimentalFeatures=false /p:RunningDotNetPack=true
|
|
|
|
- name: Publish stable NuGet packages to Artifacts
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: packages-stable
|
|
path: ./artifacts/package/release
|
|
if-no-files-found: error
|
|
|
|
run-package-validation-experimental:
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
|
with:
|
|
# Note: By default GitHub only fetches 1 commit. MinVer needs to find
|
|
# the version tag which is typically NOT on the first commit so we
|
|
# retrieve them all.
|
|
fetch-depth: 0
|
|
|
|
- name: Setup dotnet
|
|
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1
|
|
|
|
- name: dotnet pack
|
|
run: dotnet pack ./build/OpenTelemetry.proj --configuration Release /p:EnablePackageValidation=true /p:ExposeExperimentalFeatures=true /p:RunningDotNetPack=true
|
|
|
|
- name: Publish experimental NuGet packages to Artifacts
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: packages-experimental
|
|
path: ./artifacts/package/release
|
|
if-no-files-found: error
|