Automate GitHub PRs & JIRA Updates from Git Commit Commands-Single Repo
This n8n template from Intuz delivers a complete and automated solution to streamline your development workflow for a single repository.
By embedding specific keywords and a JIRA issue ID within your git commit commands, this workflow automatically creates a Pull Request in GitHub and simultaneously updates the corresponding JIRA ticket. This provides a complete, seamless integration that eliminates manual steps and keeps your project management perfectly in sync with your codebase.
How it works
This workflow acts as a powerful bridge between your Git repository and your project management tools, driven entirely by the structure of your commit messages.
GitHub Webhook Trigger: The workflow starts when a developer pushes a new commit to a specified repository in GitHub.
Parse Commit Message: A Code node extracts key information from the commit message:
The JIRA Issue Key (e.g., FF-1196). The base branch for the PR (e.g., development). Action commands like [auto-pr] and [taskcompleted].
Conditional PR Creation: An IF node checks if the [auto-pr] command is present.
If yes, it uses the GitHub node to automatically create a pull request from the developer's branch to the specified base branch. If no, this step is skipped, allowing for multiple commits before a PR is made.
Conditional JIRA Update: Another IF node checks for the [taskcompleted] command.
If yes, it uses the JIRA node to transition the corresponding issue to your "Done" status (e.g., "Task Completed" or "In Review"). If no, the JIRA issue remains in its current state, perfect for work-in-progress commits.
How to Use: Quick Start Guide
Click the "Use Template" button to import this workflow into your n8n instance.
Configure the GitHub Trigger: Open the "GitHub Push Trigger" node. It will display a unique Webhook URL. Copy this URL. In your GitHub repository, go to Settings > Webhooks > Add webhook. Paste the URL into the Payload URL field. Set the Content type to application/json. Under "Which events would you like to trigger this webhook?", select Just the push event. Click Add webhook.
Connect Your Accounts: GitHub: Select your GitHub API credential in the "Create Pull Request" node. JIRA : Select your JIRA API credential in the "Update JIRA Issue Status" node.
Customize the JIRA Transition (Important): Open the "Update JIRA Issue Status" node. In the Transition parameter, you need to set the specific status you want to move the issue to (e.g., 'Done', 'Completed', 'In Review'). You can use the ID or the exact name of the transition from your JIRA project's workflow.
Activate the Workflow: Save your changes and activate the workflow. You're ready to automate!
Example Commit Message: git commit -m "FF-1196 Implement OAuth login [auto-pr,development,taskcompleted]"
Key Requirements to Use Template
An active n8n instance. A GitHub account with repository admin permissions to create webhooks. A JIRA Cloud account with permissions to update issues. Developers who can follow the specified git commit message format.
Connect with us
Website: https://www.intuz.com/services Email: getstarted@intuz.com LinkedIn: https://www.linkedin.com/company/intuz Get Started: https://n8n.partnerlinks.io/intuz
For Custom Worflow Automation Click here- Get Started
Related Templates
Automate Free IP Analysis: NixGuard AI Summaries & Wazuh Integration
Supercharge Your Security Operations for Free Stop wasting time manually investigating suspicious IP addresses. This wo...
AI Agent with Ollama for current weather and wiki
This workflow template demonstrates how to create an AI-powered agent that provides users with current weather informati...
Automate Daily YouTrack Task Summaries to Discord by Assignee
Daily YouTrack In-Progress Tasks Summary to Discord by Assignee Keep your team in sync with a daily summary of tasks cu...
🔒 Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments