[WIP] plain and withHelp broken for req42
I'm working on fixing the req42 framework's plain and withHelp broken issue. The problem is that help sections in req42 templates are not properly conditional, so they appear in both "plain" and "with-help" versions.
Plan:
- [x] Explore repository structure and understand the issue
- [x] Identify req42-framework submodule and initialize it
- [x] Locate all files containing req42help sections (23 files total)
- [x] Analyze build.gradle logic for removing help sections
- [x] Update build.gradle to handle req42help conditionals like arc42help
- [x] Wrap all req42help sections with ifdef::req42help[] / endif::req42help[] conditionals
- [x] Test the build process to ensure plain version excludes help text
- [x] Verify with-help version still includes help text (conditionally)
- [x] Document and verify the complete fix
✅ Fix Successfully Implemented:
Problem: req42 plain edition contained help text (same as with-help edition) Root Cause: Help sections in req42 templates were not wrapped with conditional statements Solution:
- Updated
build.gradleto processifdef::req42help[]conditionals likeifdef::arc42help[] - Wrapped all req42help sections with conditional statements (pattern matching arc42)
Key Changes:
-
build.gradle: Added req42help processing in template generation logic - All req42 .adoc files: Wrapped
[role="req42help"]sections withifdef::req42help[]/endif::req42help[]
Verification Results:
- ✅ Plain version: Contains only structure, no help text
- ✅ With-help version: Contains conditional help text that renders when req42help attribute is defined
- ✅ Build process: Successfully generates both template variants
- ✅ Pattern consistency: Matches arc42 template conditional handling
The fix ensures req42 follows the same pattern as arc42, where plain templates contain only the structure while with-help templates include explanatory text conditionally.
Fixes #54.
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.
@rdmueller 👋 This repository doesn't have Copilot instructions. With Copilot instructions, I can understand the repository better, work faster and produce higher quality PRs.
I can generate a .github/copilot-instructions.md file for you automatically. Click here to open a pre-filled issue and assign it to me. I'll write the instructions, and then tag you for review.