mirror of
				https://github.com/openimsdk/open-im-server.git
				synced 2025-11-04 03:13:15 +08:00 
			
		
		
		
	* fix: part of the make rules optimization Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set github hub Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set github hub Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: scripts path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: scripts path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: scripts path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: dockerfile path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: gorelease quest Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add openim deployment build sub image Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: docker images optimize Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: dockerfile fix Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * style: fix cicd actions openimci Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * style: fix cicd actions openimci Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add sub images actions build Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: set branch Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: set branch Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * refactor: remove makefile Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: docker release v3.1.1 images optimize Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: add scripts path set Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: fix env config Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add scripts bash path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: docker release v3.1.1 images optimize Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: super docker version Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> --------- Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com>
		
			
				
	
	
		
			61 lines
		
	
	
		
			2.6 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			61 lines
		
	
	
		
			2.6 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
# Copyright © 2023 OpenIM open source community. All rights reserved.
 | 
						|
#
 | 
						|
# Licensed under the Apache License, Version 2.0 (the "License");
 | 
						|
# you may not use this file except in compliance with the License.
 | 
						|
# You may obtain a copy of the License at
 | 
						|
#
 | 
						|
#     http://www.apache.org/licenses/LICENSE-2.0
 | 
						|
#
 | 
						|
# Unless required by applicable law or agreed to in writing, software
 | 
						|
# distributed under the License is distributed on an "AS IS" BASIS,
 | 
						|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 | 
						|
# See the License for the specific language governing permissions and
 | 
						|
# limitations under the License.
 | 
						|
 | 
						|
name: Auto PR to release
 | 
						|
 | 
						|
on:
 | 
						|
  pull_request:
 | 
						|
    # types:
 | 
						|
    #   - closed
 | 
						|
  issue_comment:
 | 
						|
    types: [created]
 | 
						|
  pull_request_review_comment:
 | 
						|
    types: [created]
 | 
						|
 | 
						|
jobs:
 | 
						|
  create-pr:
 | 
						|
    runs-on: ubuntu-latest
 | 
						|
    if: github.event.pull_request.base.ref == 'main' && github.event.pull_request.merged == true
 | 
						|
    steps:
 | 
						|
        - name: Check out code
 | 
						|
          uses: actions/checkout@v3
 | 
						|
          with:
 | 
						|
            fetch-depth: 0
 | 
						|
 | 
						|
        - name: Create PR to release branch
 | 
						|
          run: |
 | 
						|
            ISSUEID=$(gh pr view ${{ github.event.pull_request.number }} --repo $OWNER/$REPO | grep -oP 'Fixes #\K\d+')
 | 
						|
            echo "===========> $ISSUEID"
 | 
						|
            ISSUE=$(gh issue view $ISSUEID --repo $OWNER/$REPO --json labels,assignees,milestone,title)
 | 
						|
            echo "===========> $ISSUE"
 | 
						|
 | 
						|
            LABELS=$(echo $ISSUE | jq -r '.labels[] | select(.name) | .name' | jq -R -r -s -c 'split("\n")[:-1] | join(",")')
 | 
						|
            ASSIGNEES=$(echo $ISSUE | jq -r '.assignees[] | select(.login) | .login' | jq -R -s -c 'split("\n")[:-1] | join(",")')
 | 
						|
            MILESTONE=$(echo $ISSUE | jq -r '.milestone | select(.title) | .title')
 | 
						|
            TITLE=$(echo $ISSUE | jq -r '.title')
 | 
						|
 | 
						|
            gh pr edit ${{ github.event.pull_request.number }} --repo $OWNER/$REPO --add-label "$LABELS" --add-assignee "$ASSIGNEES" --milestone "$MILESTONE"
 | 
						|
 | 
						|
            # git checkout -b bot/merge-to-release-$ISSUEID
 | 
						|
            # git push origin bot/merge-to-release-$ISSUEID
 | 
						|
            # gh pr create --base release --head bot/merge-to-release-$ISSUEID --title "Merge main to release" --body ""
 | 
						|
            # gh pr create --base main --head feat/auto-release-pr-624  --title "The bug is fixed" --body "$x" --repo OpenIMSDK/Open-IM-Server --reviewer "cubxxw"
 | 
						|
          continue-on-error: true
 | 
						|
          env:
 | 
						|
              GITHUB_TOKEN: ${{ secrets.BOT_GITHUB_TOKEN }}
 | 
						|
              GH_TOKEN: ${{ github.token }}
 | 
						|
              ISSUE: ${{ github.event.issue.html_url }}
 | 
						|
              OWNER: ${{ github.repository_owner }}
 | 
						|
              REPO: ${{ github.event.repository.name }}
 |