File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -75,8 +75,9 @@ for login in *; do
7575 # If there is a PR already
7676 prNumber=$( jq .number <<< " $prInfo" )
7777 epochCreatedAt=$( date --date=" $( jq -r .created_at <<< " $prInfo" ) " +%s)
78- if (( epochCreatedAt < cutoffEpoch )) ; then
79- log " $login has a retirement PR due, commenting with next steps"
78+ if jq -e .draft <<< " $prInfo" > /dev/null && (( epochCreatedAt < cutoffEpoch )) ; then
79+ log " $login has a retirement PR due, unmarking PR as draft and commenting with next steps"
80+ effect gh pr ready --repo " $ORG /$MEMBER_REPO " " $prNumber "
8081 {
8182 if (( activityCount > 0 )) ; then
8283 echo " One month has passed, @$login has been active again:"
@@ -122,7 +123,8 @@ for login in *; do
122123 -f " title=Automatic retirement of @$login " \
123124 -F " body=@-" \
124125 -f " head=$ORG :$branchName " \
125- -f " base=$mainBranch " > /dev/null
126+ -f " base=$mainBranch " \
127+ -F " draft=true" > /dev/null
126128 )
127129 else
128130 log " $login is active with $activityCount activities"
You can’t perform that action at this time.
0 commit comments