From 93806da880e3a59a860ea198711f0d3a540424b7 Mon Sep 17 00:00:00 2001 From: marisimon <104405305+marisimon@users.noreply.github.com> Date: Thu, 2 Nov 2023 11:03:00 -0600 Subject: [PATCH 1/2] Create merge-main-into-small-image.yml Configure GithubActions workflow that merges main into small-image whenever a pull request is merged into main. --- .../workflows/merge-main-into-small-image.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .github/workflows/merge-main-into-small-image.yml diff --git a/.github/workflows/merge-main-into-small-image.yml b/.github/workflows/merge-main-into-small-image.yml new file mode 100644 index 0000000..5286373 --- /dev/null +++ b/.github/workflows/merge-main-into-small-image.yml @@ -0,0 +1,18 @@ +name: merge-main-into-small-image.yml +on: + pull_request: + branches: + - main + types: + - closed +jobs: + merge-main-into-small-image: + runs-on: ubuntu-latest + + steps: + - name: Merge with main + if: github.event.pull_request.merged == true + run: | + git checkout small-image + git merge main --no-ff --no-edit + git push origin small-image From 70f66bb9fb88da3449d47b078ec1f26d3839d368 Mon Sep 17 00:00:00 2001 From: marisimon <104405305+marisimon@users.noreply.github.com> Date: Thu, 2 Nov 2023 11:18:57 -0600 Subject: [PATCH 2/2] Update merge-main-into-small-image.yml --- .github/workflows/merge-main-into-small-image.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/merge-main-into-small-image.yml b/.github/workflows/merge-main-into-small-image.yml index 5286373..14af9fc 100644 --- a/.github/workflows/merge-main-into-small-image.yml +++ b/.github/workflows/merge-main-into-small-image.yml @@ -8,11 +8,14 @@ on: jobs: merge-main-into-small-image: runs-on: ubuntu-latest + if: github.event.pull_request.merged == true + timeout-minutes: 3 steps: + - uses: actions/checkout@v4 - name: Merge with main - if: github.event.pull_request.merged == true run: | + git fetch git checkout small-image git merge main --no-ff --no-edit git push origin small-image