Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .github/workflows/feature-discovery.yml
Original file line number Diff line number Diff line change
Expand Up @@ -606,6 +606,9 @@ jobs:
LOCKFILE="/tmp/feature-tracker.lock"
TRACKER_FILE=".github/feature-tracker/backup-features.json"
TEMP_FILE="${TRACKER_FILE}.tmp"

# Get issues created count from previous step
ISSUES_CREATED="${{ steps.create-issues-from-json.outputs.issues_created || '0' }}"

# Acquire lock with timeout
exec 200>"$LOCKFILE"
Expand All @@ -620,6 +623,17 @@ jobs:
flock -u 200
exit 0
fi

# Only create PR if new issues were created (meaningful changes)
if [ "$ISSUES_CREATED" -eq 0 ]; then
echo "πŸ“Š Tracker updated with metadata only - skipping PR creation"
echo "ℹ️ Scan completed but no new features discovered"
echo "ℹ️ Updated metadata: $(date -u '+%Y-%m-%d %H:%M:%S UTC')"
flock -u 200
exit 0
fi

echo "πŸš€ Creating PR for tracker updates with $ISSUES_CREATED new issues"

# Validate JSON before committing
if [ -f "$TRACKER_FILE" ]; then
Expand Down Expand Up @@ -716,6 +730,18 @@ jobs:
else
echo "- ❌ **Issue Creation**: Failed or incomplete" >> $GITHUB_STEP_SUMMARY
fi

# Tracker Update Status
if [ "${{ steps.claude-discovery.conclusion }}" = "success" ]; then
ISSUES_COUNT="${{ steps.create-issues-from-json.outputs.issues_created || '0' }}"
if [ "$ISSUES_COUNT" -gt 0 ]; then
echo "- βœ… **Tracker Updates**: Created PR for database updates" >> $GITHUB_STEP_SUMMARY
else
echo "- πŸ“Š **Tracker Updates**: Metadata updated (no PR needed)" >> $GITHUB_STEP_SUMMARY
fi
else
echo "- ⏭️ **Tracker Updates**: Skipped (discovery failed)" >> $GITHUB_STEP_SUMMARY
fi
echo "" >> $GITHUB_STEP_SUMMARY

# Available Commands
Expand Down
Loading