From b4c17939effed38b60652ea9d649ed8525e43bbd Mon Sep 17 00:00:00 2001 From: NSMBot Date: Sat, 17 Apr 2021 20:58:52 +0000 Subject: [PATCH] Sync files with networkservicemesh/cmd-template This PR syncs files with https://github.com/networkservicemesh/cmd-template Revision: https://github.com/networkservicemesh/cmd-template/commits/53a5c472676275aa3889aba5a67583b8044b0822 commit 53a5c472676275aa3889aba5a67583b8044b0822 Author: Ed Warnicke Date: Sat Apr 17 15:57:53 2021 -0500 Migrate from 'master' default branch to 'main' (#71) Signed-off-by: NSMBot --- .github/workflows/automerge.yaml | 6 +++--- .github/workflows/ci.yaml | 6 +++--- .github/workflows/codeql-analysis.yml | 4 ++-- .github/workflows/docker-push.yaml | 4 ++-- .github/workflows/pr-for-updates.yaml | 2 +- .github/workflows/update-deployments.yaml | 6 +++--- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/automerge.yaml b/.github/workflows/automerge.yaml index 6e50fb8..732a3d5 100644 --- a/.github/workflows/automerge.yaml +++ b/.github/workflows/automerge.yaml @@ -14,13 +14,13 @@ jobs: steps: - name: Check out the code uses: actions/checkout@v2 - - name: Fetch master + - name: Fetch main run: | git remote -v - git fetch --depth=1 origin master + git fetch --depth=1 origin main - name: Only allow go.mod and go.sum changes run: | - find . -type f ! -name 'go.mod' ! -name 'go.sum' ! -name '*.yaml' ! -name '*.yml' ! -name '*.txt' ! -name '*.md' ! -name '*.conf' -exec git diff --exit-code origin/master -- {} + + find . -type f ! -name 'go.mod' ! -name 'go.sum' ! -name '*.yaml' ! -name '*.yml' ! -name '*.txt' ! -name '*.md' ! -name '*.conf' -exec git diff --exit-code origin/main -- {} + - name: Merge PR uses: ridedott/merge-me-action@master with: diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3dfa630..71cf578 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -3,7 +3,7 @@ name: ci on: push: branches: - - master + - main pull_request: jobs: yamllint: @@ -135,13 +135,13 @@ jobs: - name: Run tests run: docker run --privileged --rm $(docker build -q . --target test) - name: Find merged PR - if: github.event_name == 'push' && github.ref == 'refs/heads/master' + if: github.event_name == 'push' && github.ref == 'refs/heads/main' uses: jwalton/gh-find-current-pr@v1 id: findPr with: github-token: ${{ github.token }} - name: Publish Image - if: github.event_name == 'push' && github.ref == 'refs/heads/master' && success() && steps.findPr.outputs.number + if: github.event_name == 'push' && github.ref == 'refs/heads/main' && success() && steps.findPr.outputs.number uses: matootie/github-docker@v3.0.0 with: accessToken: ${{ github.token }} diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 292e6fd..6d85c64 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -8,10 +8,10 @@ name: "CodeQL" on: push: - branches: [master] + branches: [main] pull_request: # The branches below must be a subset of the branches above - branches: [master] + branches: [main] schedule: - cron: '0 5 * * 0' diff --git a/.github/workflows/docker-push.yaml b/.github/workflows/docker-push.yaml index 4b2157e..c6d9738 100644 --- a/.github/workflows/docker-push.yaml +++ b/.github/workflows/docker-push.yaml @@ -3,7 +3,7 @@ name: push on: push: branches: - - master + - main workflow_run: types: - completed @@ -19,7 +19,7 @@ jobs: ORG: networkservicemeshci CGO_ENABLED: 0 NAME: ${{ github.event.repository.name }} - if: ${{ github.repository != 'networkservicemesh/cmd-template' && (github.event.workflow_run.conclusion == 'success' && github.actor == 'nsmbot' || github.ref == 'refs/heads/master') }} + if: ${{ github.repository != 'networkservicemesh/cmd-template' && (github.event.workflow_run.conclusion == 'success' && github.actor == 'nsmbot' || github.ref == 'refs/heads/main') }} steps: - uses: actions/checkout@v2 - uses: actions/setup-go@v1 diff --git a/.github/workflows/pr-for-updates.yaml b/.github/workflows/pr-for-updates.yaml index b8d72e1..d09d498 100644 --- a/.github/workflows/pr-for-updates.yaml +++ b/.github/workflows/pr-for-updates.yaml @@ -20,4 +20,4 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.NSM_BOT_GITHUB_TOKEN }} BRANCH_PREFIX: "update/" - PULL_REQUEST_BRANCH: "master" + PULL_REQUEST_BRANCH: "main" diff --git a/.github/workflows/update-deployments.yaml b/.github/workflows/update-deployments.yaml index 9c132e6..16b578f 100644 --- a/.github/workflows/update-deployments.yaml +++ b/.github/workflows/update-deployments.yaml @@ -3,7 +3,7 @@ name: Update deployments-k8s reposiotry on: push: branches: - - master + - main workflow_run: types: - completed @@ -13,7 +13,7 @@ jobs: update-deployments-k8s: name: Update deployments-k8s runs-on: ubuntu-latest - if: ${{ github.repository != 'networkservicemesh/cmd-template' && (github.event.workflow_run.conclusion == 'success' && github.actor == 'nsmbot' || github.ref == 'refs/heads/master') }} + if: ${{ github.repository != 'networkservicemesh/cmd-template' && (github.event.workflow_run.conclusion == 'success' && github.actor == 'nsmbot' || github.ref == 'refs/heads/main') }} steps: - name: Checkout ${{ github.repository }} uses: actions/checkout@v2 @@ -34,7 +34,7 @@ jobs: - name: Create commit message working-directory: ${{ github.repository }} run: | - echo "Update application version to latest version from ${{ github.repository }}@master ${{ github.repository }}#${{ github.event.number }}" > /tmp/commit-message + echo "Update application version to latest version from ${{ github.repository }}@main ${{ github.repository }}#${{ github.event.number }}" > /tmp/commit-message echo "" >> /tmp/commit-message echo "${{ github.repository }} PR link: https://github.com/${{ github.repository }}/pull/${{ github.event.number }}" >> /tmp/commit-message echo "" >> /tmp/commit-message