-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(asana): add approved-section when PR is approved (#23)
- Loading branch information
Showing
1 changed file
with
15 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,10 @@ on: | |
type: string | ||
required: false | ||
description: The Asana project section for tickets with PRs that have a review requested. Requires secrets.asana-token. | ||
approved-section: | ||
type: string | ||
required: false | ||
description: The Asana project section for tickets with PRs that have been approved. Requires secrets.asana-token. | ||
merged-section: | ||
type: string | ||
required: false | ||
|
@@ -78,6 +82,17 @@ jobs: | |
asana-pat: ${{ secrets.asana-token }} | ||
trigger-phrase: ${{ inputs.trigger-phrase }} | ||
target-section: ${{ inputs.review-section }} | ||
move-to-approved-asana-ticket-job: | ||
runs-on: ubuntu-latest | ||
needs: check-for-secrets | ||
if: inputs.approved-section != '' && needs.check-for-secrets.outputs.has-asana-token == 'yes' && github.event.action == 'submitted' && github.event.review.state == 'approved' && !github.event.pull_request.draft && github.actor != 'dependabot[bot]' | ||
steps: | ||
- name: Move ticket on approval | ||
uses: mbta/[email protected] | ||
with: | ||
asana-pat: ${{ secrets.asana-token }} | ||
trigger-phrase: ${{ inputs.trigger-phrase }} | ||
target-section: ${{ inputs.approved-section }} | ||
create-asana-attachment-job: | ||
runs-on: ubuntu-latest | ||
needs: check-for-secrets | ||
|