From 8a23256c748b6a82ceb0514f94bec5a79ce44b44 Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Mon, 10 Mar 2025 15:42:35 +0100 Subject: [PATCH 1/5] WF --- .github/workflows/move-to-main-repo.yaml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/move-to-main-repo.yaml b/.github/workflows/move-to-main-repo.yaml index b1978bc..02a5d36 100644 --- a/.github/workflows/move-to-main-repo.yaml +++ b/.github/workflows/move-to-main-repo.yaml @@ -8,9 +8,16 @@ jobs: runs-on: ubuntu-latest permissions: contents: write - env: - GH_TOKEN: ${{ github.token }} + pull-requests: write + steps: + - name: Generate a token + id: generate-token + uses: actions/create-github-app-token@v1 + with: + app-id: ${{ vars.APP_ID }} + private-key: ${{ secrets.APP_PRIVATE_KEY }} + - name: Checkout repository uses: actions/checkout@v4 with: @@ -53,6 +60,8 @@ jobs: - name: Create PR if files found if: env.files_found == 'true' + env: + GH_TOKEN: ${{ steps.generate-token.outputs.token }} run: | target_repo="community-scripts/ProxmoxVE" From 1313f80583b524381109cbd2209a650889b1f62b Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Mon, 10 Mar 2025 15:46:41 +0100 Subject: [PATCH 2/5] WF --- .github/workflows/move-to-main-repo.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/move-to-main-repo.yaml b/.github/workflows/move-to-main-repo.yaml index 02a5d36..c0f2e29 100644 --- a/.github/workflows/move-to-main-repo.yaml +++ b/.github/workflows/move-to-main-repo.yaml @@ -22,6 +22,11 @@ jobs: uses: actions/checkout@v4 with: ref: main + - name: Set up GH_TOKEN + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + echo "GH_TOKEN=${GH_TOKEN}" >> $GITHUB_ENV - name: List Issues in Repository id: list_issues From 6bbca9f676f798346a21b18fe6ed590b4ca05345 Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Mon, 10 Mar 2025 15:48:15 +0100 Subject: [PATCH 3/5] WF --- .github/workflows/move-to-main-repo.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/move-to-main-repo.yaml b/.github/workflows/move-to-main-repo.yaml index c0f2e29..1667964 100644 --- a/.github/workflows/move-to-main-repo.yaml +++ b/.github/workflows/move-to-main-repo.yaml @@ -64,7 +64,7 @@ jobs: git config --global user.name "GitHub Actions" - name: Create PR if files found - if: env.files_found == 'true' + env: GH_TOKEN: ${{ steps.generate-token.outputs.token }} run: | From 471513ed2a30f5a5c6b6644f82276491087c9140 Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Mon, 10 Mar 2025 15:49:38 +0100 Subject: [PATCH 4/5] WF --- .github/workflows/move-to-main-repo.yaml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/move-to-main-repo.yaml b/.github/workflows/move-to-main-repo.yaml index 1667964..456ccb4 100644 --- a/.github/workflows/move-to-main-repo.yaml +++ b/.github/workflows/move-to-main-repo.yaml @@ -9,6 +9,8 @@ jobs: permissions: contents: write pull-requests: write + env: + GH_TOKEN: ${{ github.token }} steps: - name: Generate a token @@ -22,11 +24,6 @@ jobs: uses: actions/checkout@v4 with: ref: main - - name: Set up GH_TOKEN - env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - echo "GH_TOKEN=${GH_TOKEN}" >> $GITHUB_ENV - name: List Issues in Repository id: list_issues From 5f093e0fe93d8d520a052e770f9d161d93ce0ce8 Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Mon, 10 Mar 2025 15:50:09 +0100 Subject: [PATCH 5/5] WF --- .github/workflows/move-to-main-repo.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/move-to-main-repo.yaml b/.github/workflows/move-to-main-repo.yaml index 456ccb4..a76f1cf 100644 --- a/.github/workflows/move-to-main-repo.yaml +++ b/.github/workflows/move-to-main-repo.yaml @@ -61,7 +61,7 @@ jobs: git config --global user.name "GitHub Actions" - name: Create PR if files found - + if: ${{ env.files_found }} == "true" env: GH_TOKEN: ${{ steps.generate-token.outputs.token }} run: |