fix: using disableOverview the outcome was broken.#1609
Merged
Conversation
added 2 commits
August 27, 2025 14:31
- Problem when using disableOverview flag on which README, CHANGELOG, LICENSE and CONTRIBUTING only contained the content of the OVERVIEW page.
…erview - Added functionality to create a redirect page when the README is absent and the overview is disabled. - Introduced a new 'redirect' template to handle the redirection logic. - Updated application logic to include the new redirect page in the configuration. - Enhanced HTML engine to recognize the new redirect context.
There was a problem hiding this comment.
Pull Request Overview
This PR fixes issues with the disableOverview flag where using it caused README, CHANGELOG, LICENSE and CONTRIBUTING pages to incorrectly contain overview content, and adds missing test coverage for this functionality.
- Adds comprehensive tests for various scenarios when disableOverview is used
- Fixes incorrect page context assignment that was causing content issues
- Introduces a redirect mechanism when no README exists and overview is disabled
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| test/src/cli/cli-disable-options.spec.ts | Adds extensive test coverage for disableOverview scenarios |
| src/utils/utils.ts | Minor type annotation improvement for a return object |
| src/templates/partials/redirect.hbs | New redirect template for handling navigation when README is absent |
| src/templates/page.hbs | Adds template handling for new context types (readme, changelog, contributing, license, redirect) |
| src/app/engines/html.engine.ts | Registers the new redirect partial template |
| src/app/application.ts | Fixes context assignment and adds redirect page creation logic |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
added 6 commits
August 27, 2025 17:35
- Eliminated the redirect template and associated logic for handling missing README files. - Updated application logic to create a README page directly when the README is present. - Adjusted HTML engine and template rendering to reflect the removal of the redirect context. - Improved handling of various markdown contexts (README, CHANGELOG, CONTRIBUTING, LICENSE) in the page template.
- Updated application logic to always create an index.html page with README content when available. - Enhanced the handling of overview pages, ensuring they are created even when the README is missing and the overview is not disabled. - Improved error logging for missing markdown files, providing clearer warnings for users. - Simplified the markdown retrieval process in the MarkdownEngine by removing unnecessary promise chaining.
- Removed unused import of 'node:constants' from utils.ts. - Deleted outdated utility tests to streamline the codebase. - Added new integration tests for application and utility functions to enhance coverage and ensure functionality.
…tests - Deleted obsolete integration tests for application and utility functions to streamline the codebase. - Introduced new CLI coverage tests to enhance testing of various command executions and ensure proper functionality across different scenarios.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Uh oh!
There was an error while loading. Please reload this page.