Refactor directory structure and split property group#338
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR reorganizes the Sharprompt project into a conventional src/, tests/, samples/ directory structure and centralizes build configuration. It also adds a comprehensive test suite and introduces the full library source code under the new directory layout.
Changes:
- Moved source projects to
src/, test project totests/, and example project tosamples/, updating all project references, solution file, CI workflows, and documentation accordingly. - Added
Directory.Build.props(for shared Nullable, SourceLink settings) andDirectory.Packages.props(for centralized NuGet package version management), removing redundant properties from individual.csprojfiles. - Added extensive unit tests covering validators, options, internal types (Paginator, TextInputBuffer, Optional, etc.), fluent extensions, console driver interface, and key bindings.
Reviewed changes
Copilot reviewed 11 out of 86 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
Sharprompt.slnx |
Updated project paths to new src/, tests/, samples/ layout |
Directory.Build.props |
New shared build properties (Nullable, SourceLink) |
Directory.Packages.props |
New central package version management |
src/Sharprompt/Sharprompt.csproj |
Removed redundant props, updated relative paths for icon/README |
src/Sharprompt.SourceGenerator/Sharprompt.SourceGenerator.csproj |
Removed redundant props, versions now centralized |
tests/Sharprompt.Tests/Sharprompt.Tests.csproj |
Updated project reference path, centralized versions |
samples/Sharprompt.Example/Sharprompt.Example.csproj |
New sample project with updated references |
Sharprompt.Example/Sharprompt.Example.csproj |
Removed old project file |
.github/workflows/publish.yml |
Updated pack path to src/Sharprompt |
README.md, CONTRIBUTING.md |
Updated example project path references |
src/Sharprompt/Strings/Resource.resx |
Resource strings (English) |
src/Sharprompt/Strings/Resource.ja.resx |
Resource strings (Japanese) |
src/Sharprompt/Strings/Resource.de-DE.resx |
Resource strings (German) |
src/Sharprompt/** |
Full library source (forms, drivers, internals, options, fluent API, etc.) |
tests/Sharprompt.Tests/** |
Comprehensive test suite for validators, options, internals, fluent API, console driver |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
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.
This pull request reorganizes the project structure to follow a more conventional layout, introduces centralized configuration files for build and package management, and updates documentation to reflect these changes. The key updates include moving source, test, and sample projects into
src/,tests/, andsamples/directories, respectively, and adding shared configuration for nullable reference types and package version management.Project structure reorganization:
src/,tests/, andsamples/directories for improved clarity and maintainability. Updated references inSharprompt.slnx,.github/workflows/publish.yml, and related documentation to match the new structure. [1] [2] [3] [4] [5]Sharprompt.Example/Sharprompt.Example.csprojand added its replacement atsamples/Sharprompt.Example/Sharprompt.Example.csprojwith updated project references. [1] [2]Centralized build and package management:
Directory.Build.propsto enable nullable reference types and embed source link information across all projects.Directory.Packages.propsto manage NuGet package versions centrally, ensuring consistency and easier maintenance.Project file cleanup:
Sharprompt.SourceGenerator.csproj(now insrc/) by removing redundant properties and relying on shared configuration from the new props files.