This repository contains default community health files and reusable workflow templates for all repositories in this organization/account.
Reusable GitHub Actions workflows that can be added to any repository:
Automatically merges pull requests to the dev branch when:
- PR has the
auto-mergelabel - All CI/CD checks pass
- PR is not in draft mode
Usage:
- Go to Actions → New workflow in any repository
- Find "Auto-merge Workflow" under workflows created by this account
- Click Configure and commit
Or manually copy:
curl -o .github/workflows/auto-merge.yml \
https://raw.githubusercontent.com/taberj-git/.github/main/workflow-templates/auto-merge.ymlCreates pull requests to promote the dev branch to main for production releases.
Triggers:
- Manual: Via Actions UI or
gh workflow run - Scheduled: Every Sunday at midnight UTC (configurable)
Usage:
# Manual trigger
gh workflow run "Auto-promote to Main" -f reason="Release v1.2.0"
# Or add via Actions UI- Navigate to any repository
- Click the Actions tab
- Click New workflow
- Scroll to "Workflows created by taberj-git"
- Click Configure on the desired workflow
- Commit the file
# List available templates
gh api -H "Accept: application/vnd.github+json" \
/repos/taberj-git/.github/contents/workflow-templates
# Download template
gh api repos/taberj-git/.github/contents/workflow-templates/auto-merge.yml \
--jq '.content' | base64 -d > .github/workflows/auto-merge.ymlcd your-repository/.github/workflows
# Auto-merge workflow
curl -O https://raw.githubusercontent.com/taberj-git/.github/main/workflow-templates/auto-merge.yml
# Auto-promote workflow
curl -O https://raw.githubusercontent.com/taberj-git/.github/main/workflow-templates/auto-promote.yml
git add .
git commit -m "Add automated merge workflows"
git pushCreate these labels in your repository for the workflows to function:
gh label create "auto-merge" --color "0E8A16" \
--description "Automatically merge when checks pass"
gh label create "auto-promote" --color "1D76DB" \
--description "Ready to promote to production"Go to Settings → Actions → General → Workflow permissions:
- ✅ Read and write permissions
- ✅ Allow GitHub Actions to create and approve pull requests
For auto-merge to work:
- ✅ Enable "Allow auto-merge" in branch protection settings
- Set "Required approvals" to 0 (for solo projects)
- Configure required status checks (tests, build, etc.)
PR Created → Label with 'auto-merge' → CI/CD Runs → All Pass → Auto-merge
↓
Any Fail → No merge, comment on PR
Trigger (manual/schedule) → Check if dev ahead of main → Create/Update PR → Add 'auto-merge' label → Merged by auto-merge workflow
Edit the workflow file, line with merge_method:
merge_method: 'squash' # Options: merge, squash, rebaseEdit the auto-merge workflow to require reviews before merging.
Edit the auto-promote workflow cron schedule:
schedule:
- cron: '0 0 1 * *' # First day of month at midnightTo update these templates:
- Edit files in this repository
- Commit and push changes
- Workflows in other repos will use the latest version when reconfigured
For issues or questions about these workflows:
- Check the workflow logs in the Actions tab
- Review the setup requirements above
- Ensure labels and permissions are configured correctly