[Feature Request]: Add DataPower as a strategic adopter #9502
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Contribution triage - proposal not pursuing | |
on: | |
issues: | |
types: [labeled, opened] | |
permissions: | |
issues: write | |
jobs: | |
add-comment: | |
name: If proposal is marked as not pursuing, then post the following comment. | |
runs-on: ubuntu-latest | |
steps: | |
- name: Log github event | |
env: | |
$GITHUB_CONTEXT_LABELS: ${{ toJson(github.event.label) }} | |
run: echo "$GITHUB_CONTEXT_LABELS" | |
- name: Conditional Comment Proposal Not Pursuing | |
id: conditional-comment-proposal-not-pursuing | |
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 | |
with: | |
script: | | |
response = await github.rest.issues.listLabelsOnIssue({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
}); | |
comments = await github.rest.issues.listComments({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
}); | |
const labelArray = response.data.map((label) => label.name) | |
const commentsArray = comments.data.map(comment => comment.body) | |
const commentText = "Thank you for submitting your proposal. Unfortunately, it doesn't align with our roadmap or philosophy at this time. We value your contribution and encourage you to keep engaging with the community." | |
if (labelArray.includes('proposal: not pursuing') && !commentsArray.includes(commentText)) { | |
github.rest.issues.createComment({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
body: commentText | |
}); | |
} else { | |
console.log('No comment added because the conditions are not met.'); | |
} | |
- name: Set Output | |
if: steps.conditional-comment.outcome == 'success' | |
run: echo "Comment added successfully." |