From 9f261a081990d6942dc7adf8e1ce43e67ee3ddb8 Mon Sep 17 00:00:00 2001 From: Marius Ghita Date: Wed, 27 Dec 2023 19:31:16 +0200 Subject: [PATCH 1/2] chore: fix default branch #8308 --- .github/settings.yml | 2 +- repo.yaml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/settings.yml b/.github/settings.yml index f2e224a..275ba92 100644 --- a/.github/settings.yml +++ b/.github/settings.yml @@ -29,7 +29,7 @@ repository: has_downloads: true # Updates the default branch for this repository. - default_branch: main + default_branch: master # Either `true` to allow squash-merging pull requests, or `false` to prevent # squash-merging. diff --git a/repo.yaml b/repo.yaml index f805494..34785df 100644 --- a/repo.yaml +++ b/repo.yaml @@ -9,6 +9,7 @@ name: envoi type: library visibility: public github: + default_branch: master features: issues: true From 1b6d17cba7a8fad00f2e964c73928e77d093a8ff Mon Sep 17 00:00:00 2001 From: Marius Ghita Date: Fri, 29 Dec 2023 00:12:21 +0200 Subject: [PATCH 2/2] fix: repo-ansible workflow #8309 --- .github/workflows/repo-ansible.yaml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/.github/workflows/repo-ansible.yaml b/.github/workflows/repo-ansible.yaml index 4905bb0..d17ee74 100644 --- a/.github/workflows/repo-ansible.yaml +++ b/.github/workflows/repo-ansible.yaml @@ -1,6 +1,8 @@ name: repo-ansible on: + workflow_dispatch: + pull_request_target: paths: - 'repo.yaml' @@ -23,10 +25,16 @@ jobs: run: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - if: ${{ env.IS_PULL_REQUEST == '0' }} + uses: actions/checkout@v4 with: path: current - ref: ${{ github.event_name == 'pull_request_target' && github.head_ref || '' }} + + - if: ${{ env.IS_PULL_REQUEST == '1' }} + uses: actions/checkout@v4 + with: + path: current + ref: refs/pull/${{ github.event.pull_request.number }}/merge - uses: actions/checkout@v4 with: @@ -67,8 +75,9 @@ jobs: git config user.name github-actions git config user.email github-actions@github.com git add . - git commit -m "chore: repo-ansible run" - git push + if git commit -m "chore: repo-ansible run"; then + git push + fi - if: ${{ env.IS_PULL_REQUEST == '1' && env.REPOSITORY_CHANGED == '1' }}