Skip to content

Commit

Permalink
feat(update-codeowners-from-packages): support global codeowners (#194)
Browse files Browse the repository at this point in the history
* feat(update-codeowners-from-packages): support global codeowners

Signed-off-by: Kenji Miyake <[email protected]>

* fix

Signed-off-by: Kenji Miyake <[email protected]>

Signed-off-by: Kenji Miyake <[email protected]>
  • Loading branch information
kenji-miyake authored Nov 17, 2022
1 parent 853368c commit 242ab25
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions update-codeowners-from-packages/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ If you want to combine the automatically generated `CODEOWNERS` with the manuall
| ----------------- | -------- | ----------------------------------------------------- |
| token | true | The token for pull requests. |
| codeowners-manual | false | The path to the manually maintained `CODEOWNERS`. |
| global-codeowners | false | The GitHub IDs of global codeowners. |
| pr-base | false | Refer to `peter-evans/create-pull-request`. |
| pr-branch | false | The same as above. |
| pr-title | false | The same as above. |
Expand Down
7 changes: 7 additions & 0 deletions update-codeowners-from-packages/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ inputs:
description: ""
required: false
default: .github/CODEOWNERS-manual
global-codeowners:
description: ""
required: false
pr-base:
description: ""
required: false
Expand Down Expand Up @@ -71,6 +74,10 @@ runs:
line+=" $maintainer"
done
if [ -n "${{ inputs.global-codeowners }}" ]; then
line+=" ${{ inputs.global-codeowners }}"
fi
echo "$line" >>.github/CODEOWNERS
done
shell: bash
Expand Down

0 comments on commit 242ab25

Please sign in to comment.