Skip to content

Auto PR from jenkins #1

Auto PR from jenkins

Auto PR from jenkins #1

name: Automerge
on:
#PR时触发
pull_request:
types:
- labeled
- unlabeled
- synchronize
- opened
- edited
- ready_for_review
- reopened
- unlocked
pull_request_review:
types:
- submitted
status: {}
jobs:
automerge:
runs-on: ubuntu-latest
steps:
#运行检查
- name: Checkout the repository
uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17
- name: Cache Maven packages
uses: actions/cache@v2
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Run tests with Maven
run: mvn -B test --file pom.xml
#自动合并
- name: automerge
uses: "pascalgn/automerge-action@629929da409181990e4e638dcf84a74e11d3af66"
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
MERGE_LABELS: "automerge,!work in progress"
MERGE_METHOD: "squash"
MERGE_COMMIT_MESSAGE: "pull-request-title"