Skip to content

[TypeSpecRequirement] Add label "brownfield" to such PRs (workflow_run) #99

[TypeSpecRequirement] Add label "brownfield" to such PRs (workflow_run)

[TypeSpecRequirement] Add label "brownfield" to such PRs (workflow_run) #99

name: TypeSpec Requirement
on: pull_request
jobs:
TypeSpec-Requirement:
name: TypeSpec Requirement
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
# Required since "HEAD^" is passed to TypeSpec-Requirement.ps1
fetch-depth: 2
- name: Setup Node and run `npm ci`
uses: ./.github/actions/setup-node-npm-ci
# Outputs
# - spec-lifecycle?: "brownfield"
- run: |
eng/scripts/TypeSpec-Requirement.ps1 `
-BaseCommitish HEAD^ `
-TargetCommitish HEAD `
id: tsr-ps1
shell: pwsh
- uses: ./.github/actions/add-label-artifact
name: Upload artifact with results
with:
name: "brownfield"
value: "${{ steps.tsr-ps1.outputs.spec-lifecycle == 'brownfield' }}"