Skip to content

Use rsync as default sync, mutagen optional via --mutagen flag #86

Use rsync as default sync, mutagen optional via --mutagen flag

Use rsync as default sync, mutagen optional via --mutagen flag #86

Workflow file for this run

name: Enforce Jira Key in PR Title and Branch
on:
pull_request:
types: [opened, edited, synchronize, reopened]
jobs:
check-jira-key:
runs-on: ubuntu-latest
steps:
- name: Check PR title and branch name for Jira issue key
run: |
echo "πŸ” Checking PR title and branch name..."
JIRA_PATTERN="DTSW-[0-9]{4,}"
TITLE="${{ github.event.pull_request.title }}"
BRANCH="${{ github.event.pull_request.head.ref }}"
echo "πŸ“Œ PR Title: $TITLE"
echo "πŸ“Œ Branch: $BRANCH"
TITLE_OK=$(echo "$TITLE" | grep -E "$JIRA_PATTERN" || true)
BRANCH_OK=$(echo "$BRANCH" | grep -E "$JIRA_PATTERN" || true)
if [ -z "$TITLE_OK" ] && [ -z "$BRANCH_OK" ]; then
echo "❌ Neither PR title nor branch name contains a valid Jira issue key (DTSW-XXXX)"
echo "🚫 Merge blocked: Jira issue key must be present in either PR title or branch name"
exit 1
fi
if [ -n "$TITLE_OK" ] && [ -n "$BRANCH_OK" ]; then
echo "βœ… Jira issue key found in both PR title and branch name."
elif [ -n "$TITLE_OK" ]; then
echo "βœ… Jira issue key found in PR title."
elif [ -n "$BRANCH_OK" ]; then
echo "βœ… Jira issue key found in branch name."
fi