-
Notifications
You must be signed in to change notification settings - Fork 0
Add subsystem folder structure for design docs and requirements #81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Malcolmnixon
merged 4 commits into
main
from
copilot/add-subfolder-structure-for-subsystems
Mar 31, 2026
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
c46af6c
Initial plan
Copilot da35f88
feat: add subsystem folder structure for design docs and requirements
Copilot ffdfb2a
feat: add subsystem-level design documentation for Cli, SelfTest, Uti…
Copilot e4fc97f
feat: add system requirements and expand subsystem requirements with …
Copilot File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| # Cli Subsystem | ||
|
|
||
| <!-- TODO: This is an example design section for the Cli subsystem. Replace with your own subsystem design. --> | ||
|
|
||
| The `Cli` subsystem provides the command-line interface for the Template DotNet Tool. | ||
| It is responsible for accepting user input from the command line and routing output to | ||
| the console and an optional log file. | ||
|
|
||
| ## Overview | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Cli` subsystem acts as the primary boundary between the user's shell invocation and | ||
| the tool's internal logic. It owns argument parsing, output formatting, and error tracking. | ||
| All other subsystems receive a `Context` object from the `Cli` subsystem to read parsed | ||
| flags and write output. | ||
|
|
||
| ## Units | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Cli` subsystem contains the following software unit: | ||
|
|
||
| | Unit | File | Responsibility | | ||
| |-----------|------------------|---------------------------------------------------| | ||
| | `Context` | `Cli/Context.cs` | Argument parsing, output channels, and exit code. | | ||
|
|
||
| ## Interfaces | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Cli` subsystem exposes the following interface to the rest of the tool: | ||
|
|
||
| | Interface | Direction | Description | | ||
| |----------------------|-----------|---------------------------------------------------------------| | ||
| | `Context.Create` | Outbound | Factory method constructing a `Context` from `string[] args`. | | ||
| | `Context.WriteLine` | Outbound | Writes a message to console and optional log file. | | ||
| | `Context.WriteError` | Outbound | Writes an error to stderr and sets the error exit code. | | ||
| | `Context.ExitCode` | Outbound | Returns 0 for success or 1 when errors have been reported. | | ||
|
|
||
| ## Interactions | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Cli` subsystem has no dependencies on other tool subsystems. It uses only .NET base | ||
| class library types. The `Program` unit at system level creates the `Context` and passes it | ||
| to all subsystems that need to produce output. | ||
File renamed without changes.
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,14 +1,21 @@ | ||
| --- | ||
| resource-path: | ||
| - docs/design | ||
| - docs/design/cli | ||
| - docs/design/self-test | ||
| - docs/design/utilities | ||
| - docs/template | ||
|
|
||
| input-files: | ||
| - docs/design/title.txt | ||
| - docs/design/introduction.md | ||
| - docs/design/program.md | ||
| - docs/design/context.md | ||
| - docs/design/validation.md | ||
| - docs/design/path-helpers.md | ||
| - docs/design/cli/cli.md | ||
| - docs/design/cli/context.md | ||
| - docs/design/self-test/self-test.md | ||
| - docs/design/self-test/validation.md | ||
| - docs/design/utilities/utilities.md | ||
| - docs/design/utilities/path-helpers.md | ||
| template: template.html | ||
| table-of-contents: true | ||
| number-sections: true |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| # SelfTest Subsystem | ||
|
|
||
| <!-- TODO: This is an example design section for the SelfTest subsystem. Replace with your own subsystem design. --> | ||
|
|
||
| The `SelfTest` subsystem provides the self-validation framework for the Template DotNet Tool. | ||
| It runs a built-in suite of tests to demonstrate the tool is functioning correctly in the | ||
| deployment environment. | ||
|
|
||
| ## Overview | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
Malcolmnixon marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| The `SelfTest` subsystem is invoked when the user passes `--validate` on the command line. | ||
| It exercises the tool's own capabilities and reports a pass/fail summary. It can also write | ||
| test results to a file in TRX or JUnit XML format for integration with CI/CD pipelines. | ||
|
|
||
| ## Units | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `SelfTest` subsystem contains the following software unit: | ||
|
|
||
| | Unit | File | Responsibility | | ||
| |--------------|--------------------------|----------------------------------------------------| | ||
| | `Validation` | `SelfTest/Validation.cs` | Orchestrating and executing self-validation tests. | | ||
|
|
||
| ## Interfaces | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `SelfTest` subsystem exposes the following interface to the rest of the tool: | ||
|
|
||
| | Interface | Direction | Description | | ||
| |------------------|-----------|-----------------------------------------------------------------------| | ||
| | `Validation.Run` | Outbound | Runs all self-validation tests, prints a summary, and writes results. | | ||
|
|
||
| ## Interactions | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| | Dependency | Direction | Purpose | | ||
| |---------------|-----------|--------------------------------------------------------------| | ||
| | `Context` | Uses | Output channel for header lines, test summaries, and errors. | | ||
| | `Program` | Uses | `Program.Run` is called internally to exercise the tool. | | ||
| | `PathHelpers` | Uses | `SafePathCombine` for constructing log file paths in tests. | | ||
File renamed without changes.
File renamed without changes.
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,42 @@ | ||
| # Utilities Subsystem | ||
|
|
||
| <!-- TODO: This is an example design section for the Utilities subsystem. Replace with your own subsystem design. --> | ||
|
|
||
| The `Utilities` subsystem provides shared utility functions for the Template DotNet Tool. | ||
| It supplies reusable, independently testable helpers that are consumed by other subsystems. | ||
|
|
||
| ## Overview | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Utilities` subsystem contains general-purpose helpers that do not belong to any | ||
Malcolmnixon marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| specific feature subsystem. Its primary responsibility is safe file-path manipulation, | ||
| protecting callers from path-traversal vulnerabilities when constructing paths from | ||
| external inputs. | ||
|
|
||
| ## Units | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Utilities` subsystem contains the following software unit: | ||
|
|
||
| | Unit | File | Responsibility | | ||
| |---------------|----------------------------|---------------------------------------------| | ||
| | `PathHelpers` | `Utilities/PathHelpers.cs` | Safe path combination and traversal checks. | | ||
|
|
||
| ## Interfaces | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| The `Utilities` subsystem exposes the following interface to the rest of the tool: | ||
|
|
||
| | Interface | Direction | Description | | ||
| |-------------------------------|-----------|------------------------------------------------------------| | ||
| | `PathHelpers.SafePathCombine` | Outbound | Combines two path segments, rejecting traversal sequences. | | ||
|
|
||
| ## Interactions | ||
|
|
||
| <!-- TODO: Fill in for your project --> | ||
|
|
||
| `PathHelpers` has no dependencies on other tool units or subsystems. It uses only .NET base | ||
| class library types (`Path`, `ArgumentNullException`). | ||
Oops, something went wrong.
Oops, something went wrong.
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.