Welcome to the glam corner of .NET 9 where MVC meets main-character energy. This repo is our stage for building production-ready web apps with a confident strut, buttery-smooth tooling, and telemetry that keeps the spotlight exactly where we want it.
- Turnkey pipelines β CI keeps the runway green with linting, unit tests, and smoke checks.
- Feature-flag finesse β Azure App Configuration flips features faster than a costume change.
- Observability drip β Application Insights, custom telemetry, and coverage gates keep the receipts.
- .NET 9 SDK
- Visual Studio Code with C# Dev Kit extension
-
Build the project:
dotnet build
-
Run the project:
dotnet run
-
Run with hot reload (development):
dotnet watch run
The application will be available at https://localhost:7XXX and http://localhost:5XXX (ports will be displayed in the terminal).
This project includes VS Code tasks that you can run via:
- Ctrl+Shift+P β "Tasks: Run Task"
- Available tasks:
build,run,watch
This project uses automatic semantic versioning based on PR merge activity:
- Current Version: See
VERSIONfile in repo root - Version Format:
MAJOR.MINOR.PATCH(e.g.,0.27.9) - Automatic Updates: When a PR is merged to
main, the version is automatically bumped based on PR body content:- Major bump (
1.0.0): PR body containsBREAKING CHANGEor#major - Minor bump (
0.28.0): PR body contains#minor,feat:, orfeature - Patch bump (
0.27.10): Default for all other PRs
- Major bump (
- Artifacts: Each version bump creates:
- Updated
VERSIONfile - Git tag (e.g.,
v0.27.10) - GitHub Release with auto-generated notes
- Docker images with version labels
- .NET assemblies with embedded version
- Updated
See .github/workflows/version.yml for implementation details.
- Controllers/: MVC controllers
- Views/: Razor view templates
- Models/: Data models
- wwwroot/: Static files (CSS, JS, images)
- Program.cs: Application entry point
- appsettings.json: Configuration settings
To debug the application in VS Code:
- Press F5 to start debugging
- Or use Ctrl+Shift+P β "Debug: Start Debugging"
The debugger will launch the application and open it in your default browser.
dotnet testtriggers all suites, including the Playwright smoke tests inDemo1.PlaywrightTests.- On the first run Playwright downloads headless browser binaries automatically; alternatively, install them explicitly by executing
pwsh tests/Demo1.PlaywrightTests/bin/Debug/net9.0/playwright.ps1 installfrom the repository root after a build (ensure your working directory is the solution root). - The GitHub Actions workflow installs the Playwright CLI (
Microsoft.Playwright.CLI) so CI runs the same headless checks.
- Docs hub:
docs/README.md - Architecture:
docs/architecture.md - Coding & docs conventions:
docs/conventions.md - Configuration:
docs/configuration.md - Testing guidelines:
docs/testing.md
- The project generates XML docs on build:
bin/<Configuration>/<TargetFramework>/Demo1.xml - All public APIs should include
///XML comments (enforced by the Documentation Helper CI agent)
- Client-side libraries (Bootstrap, jQuery, validation) are managed with LibMan. Run
libman restoreto populatewwwroot/lib/when working locally. - The repository currently contains restored files in
wwwroot/lib/so Docker builds and CI do not need to fetch from CDNs at build time. If you prefer not to commit vendor files, update the Dockerfile and CI to runlibman restoreduring the build.
- The docs include an example for enabling Swagger, but it is not enabled by default in
Program.cs. - To enable Swagger locally during development, you can add the minimal services and middleware in
Program.cs(or set a feature flag):
// Example: enable when configuration flag is set or in Development
if (app.Environment.IsDevelopment() || builder.Configuration.GetValue<bool>("EnableSwagger", false))
{
app.UseSwagger();
app.UseSwaggerUI();
}- CI may produce coverage artifacts used by badges and checks. To generate coverage locally with Coverlet (example):
dotnet test /p:CollectCoverage=true /p:CoverletOutputFormat=coberturaCheck your CI workflow for the exact coverage collector and reporting steps if you rely on published coverage reports.
- The Docker build expects
wwwroot/lib/to contain client libs (this repository currently tracks them). If you change that approach, ensure CI installs LibMan or restores client libraries during the Docker build to avoid publish failures.
This project is configured with GitHub Actions workflows and Copilot Custom Agents:
- π¨ Build & Test: Runs on every push and PR
- π Deploy: Handles production deployments
- π€ Copilot Agents: Custom agents for code review and quality checks
- Code Reviewer: Reviews PRs for MVC best practices
- Build Validator: Ensures successful builds
- Security Auditor: Scans for vulnerabilities (weekly + PRs)
- Documentation Helper: Maintains docs quality
- Push your code to trigger automated builds
- Create a pull request to activate code review agents
- Agents provide feedback and suggestions automatically
- Configure deployment secrets for production releases
See .github/copilot-instructions.md for detailed agent configuration.
This project includes custom GitHub Copilot agents that you can chat with directly in VS Code!
Use @agent-name in Copilot Chat to invoke them:
Reviews your code for quality and best practices.
@code-reviewer look at this controller
@code-reviewer check my security implementationValidates project files and dependencies.
@build-validator check my .csproj file
@build-validator analyze dependenciesScans for security vulnerabilities.
@security-auditor scan this file
@security-auditor check for SQL injection risksHelps improve documentation.
@doc-helper generate XML comments
@doc-helper check documentation coverageHelps triage GitHub issues.
@issue-helper classify this issue
@issue-helper suggest labels- Open Copilot Chat (Ctrl+Shift+I)
- Type
@to see available agents - Select an agent and ask your question
- Get intelligent, context-aware assistance!
# Review current file
@code-reviewer analyze this controller for MVC best practices
# Check security
@security-auditor scan for authentication issues
# Validate build
@build-validator check package versions
# Improve docs
@doc-helper add XML comments to selected code