Skip to content

Commit

Permalink
action para criar branch ao fazer assign (#215)
Browse files Browse the repository at this point in the history
Co-authored-by: Andre Almeida <[email protected]>
  • Loading branch information
fabiuhp and aalmeida00 authored Nov 23, 2023
1 parent 7a1d976 commit 9d12b0b
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/createBranchAssign.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Create Branch on Assignment

on:
issues:
types:
- assigned

jobs:
create-branch:
runs-on: ubuntu-latest

steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Set up Git
run: |
git config user.name "${{ github.actor }}"
git config user.email "${{ github.actor }}@users.noreply.github.com"
- name: Create Branch
run: |
ISSUE_NUMBER=$(echo ${{ github.event.issue.number }})
BRANCH_NAME="issue-${ISSUE_NUMBER}"
git checkout -b $BRANCH_NAME
git push origin $BRANCH_NAME
- name: Notify Success
run: echo "Branch created successfully!"

0 comments on commit 9d12b0b

Please sign in to comment.