Skip to content

Commit

Permalink
Trigger add-task-to-project when PR marked ready for review (#3376)
Browse files Browse the repository at this point in the history
Task/Issue URL:
https://app.asana.com/0/414235014887631/1207931637636063/f
Tech Design URL:
CC:

**Description**:

Trigger add-task-to-project when PR marked ready for review.

Counterpart of duckduckgo/macos-browser#3273.

**Steps to test this PR**:

* Create a copy of this branch and open a draft PR. 
* Mark as ready for review and check if the "Add Task to App Board
Project" action is successful.

**Definition of Done (Internal Only)**:

* [ ] Does this PR satisfy our [Definition of
Done](https://app.asana.com/0/1202500774821704/1207634633537039/f)?

---
###### Internal references:
[Software Engineering
Expectations](https://app.asana.com/0/59792373528535/199064865822552)
[Technical Design
Template](https://app.asana.com/0/59792373528535/184709971311943)
  • Loading branch information
dus7 authored Sep 24, 2024
1 parent d57df6d commit d0f5dfd
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/pr-task-url.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Asana PR Task URL

on:
pull_request:
types: [opened, edited, closed, synchronize, review_requested]
types: [opened, edited, closed, synchronize, review_requested, ready_for_review]

jobs:

Expand All @@ -14,6 +14,8 @@ jobs:

runs-on: ubuntu-latest

if: ${{ !github.event.pull_request.draft }}

outputs:
task_id: ${{ steps.get-task-id.outputs.task_id }}
task_in_project: ${{ steps.check-board-membership.outputs.task_in_project }}
Expand Down Expand Up @@ -47,7 +49,7 @@ jobs:
- name: Add Task to the App Board Project
id: add-task-to-project
if: ${{ github.event.action == 'opened' && steps.check-board-membership.outputs.task_in_project == '0' }}
if: ${{ (github.event.action == 'opened' || github.event.action == 'ready_for_review') && steps.check-board-membership.outputs.task_in_project == '0' }}
env:
ASANA_ACCESS_TOKEN: ${{ secrets.ASANA_ACCESS_TOKEN }}
ASANA_PROJECT_ID: ${{ vars.IOS_APP_BOARD_ASANA_PROJECT_ID }}
Expand Down

0 comments on commit d0f5dfd

Please sign in to comment.