Moved from https to ssh for Windows in Github Actions

pull/21975/head
Andrey Senyaev 3 years ago
parent 40d2904f3d
commit 2b5b192cd7
  1. 16
      .github/workflows/PR-3.4-W10.yaml

@ -30,25 +30,25 @@ jobs:
- name: Clean - name: Clean
run: cd ${{ github.workspace }} && rm -rf * run: cd ${{ github.workspace }} && rm -rf *
- name: Fetch opencv - name: Fetch opencv
run: cd ${{ github.workspace }} && git clone --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv.git https://github.com/opencv/opencv.git run: cd ${{ github.workspace }} && git clone --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv.git git@github.com:opencv/opencv.git
- name: Merge opencv with ${{ env.SOURCE_BRANCH_NAME }} branch - name: Merge opencv with ${{ env.SOURCE_BRANCH_NAME }} branch
run: | run: |
cd ${{ github.workspace }}\opencv cd ${{ github.workspace }}\opencv
git config user.email "opencv.ci" git config user.email "opencv.ci"
git config user.name "opencv.ci" git config user.name "opencv.ci"
git pull -v "https://github.com/${{ env.PR_AUTHOR_FORK }}" "${{ env.SOURCE_BRANCH_NAME }}" git pull -v "git@github.com:${{ env.PR_AUTHOR_FORK }}" "${{ env.SOURCE_BRANCH_NAME }}"
- name: Fetch opencv_extra - name: Fetch opencv_extra
run: cd ${{ github.workspace }} && git clone --single-branch --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv_extra.git https://github.com/opencv/opencv_extra.git run: cd ${{ github.workspace }} && git clone --single-branch --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv_extra.git git@github.com:opencv/opencv_extra.git
- name: Merge opencv_extra with ${{ env.SOURCE_BRANCH_NAME }} branch - name: Merge opencv_extra with ${{ env.SOURCE_BRANCH_NAME }} branch
shell: bash shell: bash
run: | run: |
RET=$(git ls-remote --heads "https://github.com/${{ env.PR_AUTHOR }}/opencv_extra" "${{ env.SOURCE_BRANCH_NAME }}") || true RET=$(git ls-remote --heads "git@github.com:${{ env.PR_AUTHOR }}/opencv_extra" "${{ env.SOURCE_BRANCH_NAME }}") || true
if [[ ! -z "$RET" ]]; then if [[ ! -z "$RET" ]]; then
echo "Merge opencv_extra with ${{ env.SOURCE_BRANCH_NAME }} branch" echo "Merge opencv_extra with ${{ env.SOURCE_BRANCH_NAME }} branch"
cd opencv_extra cd opencv_extra
git config user.email "opencv.ci" git config user.email "opencv.ci"
git config user.name "opencv.ci" git config user.name "opencv.ci"
git pull -v "https://github.com/${{ env.PR_AUTHOR }}/opencv_extra" "${{ env.SOURCE_BRANCH_NAME }}" git pull -v "git@github.com:${{ env.PR_AUTHOR }}/opencv_extra" "${{ env.SOURCE_BRANCH_NAME }}"
else else
echo "No merge since ${{ env.PR_AUTHOR }}/opencv_extra does not have branch ${{ env.SOURCE_BRANCH_NAME }}" echo "No merge since ${{ env.PR_AUTHOR }}/opencv_extra does not have branch ${{ env.SOURCE_BRANCH_NAME }}"
fi fi
@ -145,15 +145,15 @@ jobs:
- name: Clean - name: Clean
run: cd ${{ github.workspace }} && rm -rf * run: cd ${{ github.workspace }} && rm -rf *
- name: Fetch opencv - name: Fetch opencv
run: cd ${{ github.workspace }} && git clone --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv.git https://github.com/opencv/opencv.git run: cd ${{ github.workspace }} && git clone --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv.git git@github.com:opencv/opencv.git
- name: Merge opencv with ${{ env.SOURCE_BRANCH_NAME }} branch - name: Merge opencv with ${{ env.SOURCE_BRANCH_NAME }} branch
run: | run: |
cd ${{ github.workspace }}\opencv cd ${{ github.workspace }}\opencv
git config user.email "opencv.ci" git config user.email "opencv.ci"
git config user.name "opencv.ci" git config user.name "opencv.ci"
git pull -v "https://github.com/${{ env.PR_AUTHOR_FORK }}" "${{ env.SOURCE_BRANCH_NAME }}" git pull -v "git@github.com:${{ env.PR_AUTHOR_FORK }}" "${{ env.SOURCE_BRANCH_NAME }}"
- name: Fetch opencv_contrib - name: Fetch opencv_contrib
run: cd ${{ github.workspace }} && git clone --single-branch --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv_contrib.git --depth 1 https://github.com/opencv/opencv_contrib.git run: cd ${{ github.workspace }} && git clone --single-branch --branch ${{ env.TARGET_BRANCH_NAME }} --reference ${{ env.GIT_CACHE }}\opencv_contrib.git --depth 1 git@github.com:opencv/opencv_contrib.git
- name: Configure OpenCV Contrib - name: Configure OpenCV Contrib
run: | run: |
mkdir ${{ github.workspace }}\opencv-contrib-build && cd ${{ github.workspace }}\opencv-contrib-build mkdir ${{ github.workspace }}\opencv-contrib-build && cd ${{ github.workspace }}\opencv-contrib-build

Loading…
Cancel
Save