- run workflow.sh from this repository
name: gitflow-automation
on:
pull_request:
types: [closed]
jobs:
create-auto-pr:
if: github.event.pull_request.merged == true
name: Gitflow Automation
runs-on: ubuntu-latest
steps:
- uses: JonahArends/gitflow-automation-MSTeam-webhook@master
env:
BASE_BRANCH: "main"
BRANCH_PREFIX: "hotfix"
TARGET_BRANCH: "develop"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MSTEAMS: "true"
MSTEAMS_WH: ${{ secrets.MSTEAMS_WH }} #secret recommended
BASE_BRANCH
: Base-branch of the pull request that is to trigger the workflowBRANCH_PREFIX
: Prefix of the branch that is to trigger the workflowTARGET_BRANCH
: Branch into which the workflow should automatically mergeGITHUB_TOKEN
: Your Github token for authenticationMSTEAMS
: Turn the Microsoft Teams webhook on ("true"
) or off ("false"
)MSTEAMS_WH
: Create a Github secret for the Microsoft Teams webhook URL with the name "MSTEAMS_WH"
- run workflow.sh from own repository
name: gitflow-automation
on:
pull_request:
types: [closed]
jobs:
create-auto-pr:
if: github.event.pull_request.merged == true
name: Gitflow Automation
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
ref: main
- name: gitflow-automation
run: |
chmod +x path/to/workflow.sh && path/to/workflow.sh
env:
BASE_BRANCH: "main"
BRANCH_PREFIX: "hotfix"
TARGET_BRANCH: "develop"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MSTEAMS: "true"
MSTEAMS_WH: ${{ secrets.MSTEAMS_WH }} #secret recommended
BASE_BRANCH
: Base-branch of the pull request that is to trigger the workflowBRANCH_PREFIX
: Prefix of the branch that is to trigger the workflowTARGET_BRANCH
: Branch into which the workflow should automatically mergeGITHUB_TOKEN
: Your Github token for authenticationMSTEAMS
: Turn the Microsoft Teams webhook on ("true"
) or off ("false"
)MSTEAMS_WH
: Create a Github secret for the Microsoft Teams webhook URL with the name "MSTEAMS_WH"
Maintenance or “hotfix” branches are used to quickly patch production releases. Hotfix branches are a lot like release branches and feature branches except they're based on main instead of develop.
- workflow.sh aus diesem Repository ausführen
name: gitflow-automation
on:
pull_request:
types: [closed]
jobs:
create-auto-pr:
if: github.event.pull_request.merged == true
name: Gitflow Automation
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
ref: main
- name: gitflow-automation
run: |
chmod +x path/to/workflow.sh && path/to/workflow.sh
env:
BASE_BRANCH: "main"
BRANCH_PREFIX: "hotfix"
TARGET_BRANCH: "develop"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MSTEAMS: "true"
MSTEAMS_WH: ${{ secrets.MSTEAMS_WH }} #secret empfohlen
BASE_BRANCH
: Base-branch, des Pull Requests, der den Workflow auslösen sollBRANCH_PREFIX
: Prefix der Branch, die den Workflow auslösen sollTARGET_BRANCH
: Branch, in die der Workflow automatisch mergen sollGITHUB_TOKEN
: Dein Github-Token zur AuthentifizierungMSTEAMS
: Microsoft Teams Webhook an ("true"
) oder aus ("false"
) schaltenMSTEAMS_WH
: Erstelle ein Github Secret für die Microsoft Teams Webhook-URL mit dem Namen "MSTEAMS_WH"
- workflow.sh aus eigenem Repository ausführen
name: gitflow-automation
on:
pull_request:
types: [closed]
jobs:
create-auto-pr:
if: github.event.pull_request.merged == true
name: Gitflow Automation
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
ref: main
- name: gitflow-automation
run: |
chmod +x path/to/workflow.sh && path/to/workflow.sh
env:
BASE_BRANCH: "main"
BRANCH_PREFIX: "hotfix"
TARGET_BRANCH: "develop"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MSTEAMS: "true"
MSTEAMS_WH: ${{ secrets.MSTEAMS_WH }} #secret empfohlen
BASE_BRANCH
: Base-branch, des Pull Requests, der den Workflow auslösen sollBRANCH_PREFIX
: Prefix der Branch, die den Workflow auslösen sollTARGET_BRANCH
: Branch, in die der Workflow automatisch mergen sollGITHUB_TOKEN
: Dein Github-Token zur AuthentifizierungMSTEAMS
: Microsoft Teams Webhook an ("true"
) oder aus ("false"
) schaltenMSTEAMS_WH
: Erstelle ein Github Secret für die Microsoft Teams Webhook-URL mit dem Namen "MSTEAMS_WH"
Wartungs- oder "Hotfix"-Branches werden verwendet, um Produktionsversionen schnell zu patchen. Hotfix-Branches sind ähnlich wie Release-Branches und Feature-Branches, nur dass sie auf Main statt auf Develop basieren.
Dies ist der einzige Branch, der direkt von main abzweigen sollte. Sobald die Korrektur abgeschlossen ist, sollte sie sowohl in den Haupt- als auch in den Entwicklungsbranch (oder den aktuellen Veröffentlichungsbranch) eingebunden werden, und der Hauptbranch sollte mit einer aktualisierten Versionsnummer versehen werden.