Skip to content

Commit

Permalink
Merge pull request apache#3845 from hansva/main
Browse files Browse the repository at this point in the history
[INFRA] add issues and PR to milestones
  • Loading branch information
hansva authored Apr 21, 2024
2 parents 93cbebb + 4e5e667 commit ad8e151
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/pr_assign_milestone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,14 @@ jobs:
sort: 'due_on',
direction: 'asc'
})
const milestone = list.data
console.log(milestone)
return milestone.length == 0 ? null : milestone[0].number
for( const milestone of list.data) {
if ( milestone.due_on !== null ) {
console.log(milestone)
return milestone.number
break;
}
}
return null
- name: add milestone
uses: actions/github-script@v7
with:
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/self_assign.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,14 @@ jobs:
sort: 'due_on',
direction: 'asc'
})
const milestone = list.data
return milestone.length == 0 ? null : milestone[0].number
for( const milestone of list.data) {
if ( milestone.due_on !== null ) {
console.log(milestone)
return milestone.number
break;
}
}
return null
- uses: actions/github-script@v7
with:
script: |
Expand Down

0 comments on commit ad8e151

Please sign in to comment.