chore(ci): Adjust pumpkin-plugin-wit CI workflows (#3454)
* chore(ci): Adjust `pumpkin-plugin-wit` CI workflows * Fix close-prs workflow Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Signed-off-by: Demetrius Kanios <demetrius@kanios.net> --------- Signed-off-by: Demetrius Kanios <demetrius@kanios.net> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
This commit is contained in:
parent
1ad73fff1e
commit
bbd7690dd1
28
.github/workflows/close-prs.yml
vendored
Normal file
28
.github/workflows/close-prs.yml
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
name: Close PRs
|
||||
|
||||
on:
|
||||
pull_request_target:
|
||||
types: [opened, reopened]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
pull-requests: write
|
||||
|
||||
jobs:
|
||||
manage-prs:
|
||||
runs-on: ubuntu-slim
|
||||
steps:
|
||||
- name: "Close PR(s)"
|
||||
run: |
|
||||
if [ "${{ github.event_name }}" = "pull_request" ]; then
|
||||
echo "${{ github.event.pull_request.number }}"
|
||||
else
|
||||
gh pr list --state open --limit 200 --json number --jq '.[].number'
|
||||
fi | while read pr; do
|
||||
if [ -n "$pr" ]; then
|
||||
echo "Closing PR #$pr"
|
||||
gh pr close $pr --comment "This repository does not accept direct pull requests. See #44 for details."
|
||||
fi
|
||||
done
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
15
.github/workflows/test-bindgen.yml
vendored
15
.github/workflows/test-bindgen.yml
vendored
@ -1,20 +1,11 @@
|
||||
name: Test `wit-bindgen` against the WIT
|
||||
on: [push, pull_request, workflow_dispatch]
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
pull-requests: write
|
||||
|
||||
jobs:
|
||||
test-bindgen:
|
||||
name: Test with `wit-bindgen`
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v7
|
||||
|
||||
- name: Setup `wit-bindgen`
|
||||
uses: bytecodealliance/actions/wit-bindgen/setup@v1
|
||||
|
||||
- name: Test WIT
|
||||
run: wit-bindgen rust v0.1
|
||||
- uses: actions/checkout@v7
|
||||
- uses: bytecodealliance/actions/wit-bindgen/setup@v1
|
||||
- run: wit-bindgen rust v0.1
|
||||
|
||||
Loading…
Reference in New Issue
Block a user