Skip to content

[workflow-style] Normalize report formatting for daily-code-metrics #11498

@github-actions

Description

@github-actions

Workflow to Update

Workflow File: .github/workflows/daily-code-metrics.md
Issue: This workflow generates code metrics reports with extensive templates that use h2 (##) headers throughout, which should be h3 (###) for proper document hierarchy

Required Changes

Update the discussion template to use proper header levels across all sections.

1. Fix Header Levels in Main Template

The discussion template (lines 247-393) uses many ## headers which should be ###:

Main sections to update:

  • ## 📊 Visualizations### 📊 Visualizations
  • ## 💡 Insights & Recommendations### 💡 Insights & Recommendations

Subsections inside <details> to update:

  • ## Size Metrics### Size Metrics
  • ## Quality Indicators### Quality Indicators
  • ## Test Coverage### Test Coverage
  • ## Code Churn (Last 7 Days)### Code Churn (Last 7 Days)
  • ## Workflow Metrics### Workflow Metrics
  • ## Documentation### Documentation
  • ## Quality Score: XX/100### Quality Score: XX/100

Fourth-level headers:

  • ### Lines of Code by Language#### Lines of Code by Language
  • ### Lines of Code by Directory#### Lines of Code by Directory
  • ### Most Active Files#### Most Active Files
  • ### Component Breakdown#### Component Breakdown

2. Add Formatting Guidelines

Add this section before the "Report Format" heading (around line 238):

## Report Formatting Guidelines

**IMPORTANT**: Use h3 (###) or lower for all headers in the discussion report to maintain proper document hierarchy. The discussion title serves as h1.

**Structure**:
- Main sections: h3 (###) - e.g., "### 📊 Visualizations"
- Subsections: h4 (####) - e.g., "#### LOC Distribution by Language"
- Detail sections inside `<details>`: h3/h4 as appropriate

**Progressive Disclosure**: Keep executive summary and key visualizations visible. Use `<details>` tags for detailed metrics tables (as already shown in template).

3. Update All Template Headers

Systematically replace header levels in the template body (lines 247-393):

  1. All standalone #####
  2. All ### nested under sections → ####
  3. Maintain the existing <details> structure (already good)

Positive Notes:

  • This workflow already uses <details> tags excellently for "📈 Detailed Metrics"
  • The structure and organization are very clear
  • Chart generation instructions are comprehensive

Design Principles

The updated workflow will create reports that:

  1. Build trust through clarity: Proper hierarchy improves scannability of dense metrics
  2. Maintain consistency: Aligns with other daily reporting workflows
  3. Support navigation: Better structured for jumping between sections

Example Reference

See daily-repo-chronicle.md for a similar workflow that uses proper header levels throughout.

Testing

After updating:

  1. Run the workflow with workflow_dispatch
  2. Check the generated discussion for proper header hierarchy
  3. Verify the detailed metrics section inside <details> uses h3/h4 appropriately
  4. Confirm no h2 (##) headers appear in the report body

AI generated by Workflow Normalizer

  • expires on Jan 30, 2026, 12:24 PM UTC

Metadata

Metadata

Labels

cookieIssue Monster Loves Cookies!documentationImprovements or additions to documentationenhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions