---
title: TimeWarp Software
tagline: Time to Build
description: A showcase of TimeWarp Engineering's NuGet libraries and open source projects.
---
A showcase of [TimeWarp Engineering](https://github.com/TimeWarpEngineering)'s
NuGet libraries and open source projects.
This site is **agent-first**: every page is generated from canonical markdown,
and that markdown is served directly to AI agents. This page is available as
[markdown](/index.md) — no HTML parsing required.
[Browse the packages](/packages/) — every TimeWarp NuGet has a landing page,
generated straight from the NuGet catalog — or pick up an [Agent Skill](/skills/)
for your AI coding agent. Agents: start at [/llms.txt](/llms.txt)
or grab the whole site as [/llms-full.txt](/llms-full.txt).
Optional support: the [tip jar](/tip/) (content stays free; payment only at
`/api/tip` when tips are enabled).
---
---
title: Tip jar
tagline: Voluntary support
description: Free docs for the optional x402 tip jar. Site content stays free; payment only at /api/tip.
---
All catalog, skill, project, and discovery content on timewarp.software is
**free**. We never require payment to crawl, train on, or use these materials.
If an agent (or human) found them useful, they may optionally tip via our
x402 tip endpoint. Tips are voluntary, fixed-amount micropayments in USDC;
they are not a fee for content access.
## What never requires payment
These surfaces stay free and must **never** return HTTP 402 from tip middleware:
- This page (`/tip/`, [markdown twin](/tip/index.md))
- Homepage, packages, skills, projects
- `/llms.txt`, `/llms-full.txt`, package and skills JSON indexes
- `/.well-known/*` discovery files
- Every page’s markdown twin (`…/index.md`)
## How to tip
| Item | Value |
|------|--------|
| Endpoint | `GET` or `POST` **`/api/tip`** (trailing slash accepted; `/api` is a discovery alias) |
| Amount | **`$0.10` USDC** (`exact` scheme) |
| Network | Base mainnet `eip155:8453` — **live** |
| Asset | USDC `0x833589fCD6eDb6E08f4c7c32D4f71b54bdA02913` |
| Protocol | [x402](https://x402.org/) — HTTP 402 + payment headers |
| Facilitator | Coinbase CDP `https://api.cdp.coinbase.com/platform/v2/x402` |
Testnet (Base Sepolia `eip155:84532`) is used only in local development —
the live endpoint accepts real mainnet USDC exclusively.
### Responses on `/api/tip` only
| Condition | Status |
|-----------|--------|
| Tips disabled or misconfigured | **503** (never 402) |
| Tips enabled, no payment | **402** + `PAYMENT-REQUIRED` |
| Payment verified and settled | **200** thank-you + `PAYMENT-RESPONSE` |
Payment **never** applies to free documentation or catalog routes.
## For agents
1. Read this page or `/llms.txt` (Docs lists free tip docs; Optional lists the tip action URL).
2. Call `/api/tip` with an x402-capable client. Buyer quickstart: [docs.x402.org](https://docs.x402.org/getting-started/quickstart-for-buyers).
3. On success, expect JSON (or markdown if you send `Accept: text/markdown`) saying thank you.
Tips do not unlock content. Free routes stay free under this design.
---
---
title: TimeWarp.AspNetCore.Blazor.Templates
description: TimeWarp Templates for ASP.NET Core Blazor
type: package
latest: 5.0.152+5.0.301
stable: 5.0.152+5.0.301
repository: https://github.com/TimeWarpEngineering/timewarp-architecture
---
TimeWarp Templates for ASP.NET Core Blazor
| | |
|---|---|
| Latest stable | `5.0.152+5.0.301` |
| Downloads | 68,535 |
| Last published | 2021-06-18 |
| Target frameworks | `.NETStandard2.1` |
## Install
```sh
dotnet add package TimeWarp.AspNetCore.Blazor.Templates
```
[NuGet](https://www.nuget.org/packages/TimeWarp.AspNetCore.Blazor.Templates) · [Source](https://github.com/TimeWarpEngineering/timewarp-architecture) · Part of the [timewarp-architecture](/projects/timewarp-architecture/) family
See [TimeWarp.Architecture](/packages/timewarp.architecture/) for the full documentation of this family.
---
---
title: timewarp-simple-icons
description: All of the simple-icons wrapped as Blazor components.
type: package
latest: 16.18.0
stable: 16.18.0
repository: https://github.com/TimeWarpEngineering/timewarp-simple-icons
---
All of the simple-icons wrapped as Blazor components.
| | |
|---|---|
| Latest stable | `16.18.0` |
| Downloads | 26,367 |
| Last published | 2026-04-26 |
| Target frameworks | `net8.0` |
## Install
```sh
dotnet add package timewarp-simple-icons
```
[NuGet](https://www.nuget.org/packages/timewarp-simple-icons) · [Source](https://github.com/TimeWarpEngineering/timewarp-simple-icons)
---
[](https://dotnet.microsoft.com)
[](https://github.com/TimeWarpEngineering/timewarp-simple-icons)
[](https://discord.gg/7F4bS2T)
[](https://www.nuget.org/packages/timewarp-simple-icons/)
[](https://www.nuget.org/packages/timewarp-simple-icons/)
[](https://github.com/TimeWarpEngineering/timewarp-simple-icons/issues)
[](https://github.com/TimeWarpEngineering/timewarp-simple-icons)
[](https://unlicense.org)
[](https://twitter.com/intent/tweet?url=https://github.com/TimeWarpEngineering/timewarp-simple-icons)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# timewarp-simple-icons

All [simple-icons](https://github.com/simple-icons/simple-icons) wrapped as Blazor components.
See and search all at https://simpleicons.org/
## Give a Star! :star:
If you like or are using this project please give it a star. Thank you!
## Usage
```razor
```
Outputs

## Installation
You can see the latest NuGet packages from the official [TimeWarp NuGet page](https://www.nuget.org/profiles/TimeWarp.Enterprises).
* [timewarp-simple-icons](https://www.nuget.org/packages/timewarp-simple-icons/) [](https://www.nuget.org/packages/timewarp-simple-icons/)
```console
dotnet add package timewarp-simple-icons
```
## License
[](https://unlicense.org)
## Contributing
Time is of the essence. Before developing a Pull Request I recommend opening a [discussion](https://github.com/TimeWarpEngineering/timewarp-simple-icons/discussions).
Please feel free to make suggestions and help out with the [documentation](https://timewarpengineering.github.io/timewarp-simple-icons/).
Please refer to [Markdown](http://daringfireball.net/projects/markdown/) for how to write markdown files.
### Steps to publish NuGet package
* [ ] Clone the [simple-icons](https://github.com/simple-icons/simple-icons) repo.
* [ ] Set the PowerShell variable `$simple_icons` to the path where you cloned the simple-icons repo in the above step. (Add `$simple_icons = ""` to your profile)
* [ ] Ensure your copy of the simple-icons repo is up to date by running (`update.ps1`).
* [ ] Set the Version in `timewarp-simple-icons/source/timewarp-simple-icons/timewarp-simple-icons.csproj` to the same version that is in `simple-icons/package.json`.
* [ ] Transform the cloned [simple-icons](https://github.com/simple-icons/simple-icons) into razor files by running `transform.ps1`.
* [ ] Run the test app to make sure the icons render properly.
* [ ] Update `releases.md`.
* [ ] Commit and push the changes to GitHub.
* [ ] Set the PowerShell variable `$Nuget_Key` value.
* [ ] Publish to NuGet by running `publish.ps1`.
* [ ] Tweet to let people know.
## Contact
Sometimes the GitHub notifications get lost in the shuffle. If you file an [issue](https://github.com/TimeWarpEngineering/timewarp-simple-icons/issues) and don't get a response in a timely manner feel free to contact us on our [Discord server](https://discord.gg/A55JARGKKP).
[](https://discord.gg/7F4bS2T)
## References
https://github.com/simple-icons/simple-icons
### Commands used
```PowerShell
dotnet new sln
dotnet new razorclasslib -n timewarp-simple-icons
dotnet sln add .\Source\timewarp-simple-icons\timewarp-simple-icons.csproj
dotnet new tool-manifest
dotnet tool install dotnet-cleanup
dotnet cleanup -y
```
---
---
title: TimeWarp.State
description: A Blazor state management library by TimeWarp
type: package
latest: 12.0.0-beta.1
stable: 11.0.3
repository: https://github.com/TimeWarpEngineering/timewarp-state
---
A Blazor state management library by TimeWarp
| | |
|---|---|
| Latest stable | `11.0.3` |
| Latest prerelease | `12.0.0-beta.1` |
| Downloads | 25,222 |
| Last published | 2025-08-20 |
| Target frameworks | `net8.0` |
## Install
```sh
dotnet add package TimeWarp.State
dotnet add package TimeWarp.State --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.State) · [Source](https://github.com/TimeWarpEngineering/timewarp-state) · Part of the [timewarp-state](/projects/timewarp-state/) family
---
[](https://github.com/TimeWarpEngineering/timewarp-state)
[](https://github.com/TimeWarpEngineering/timewarp-state/actions)
[](https://github.com/TimeWarpEngineering/timewarp-state)
[](https://github.com/TimeWarpEngineering/timewarp-state/issues)
[](https://github.com/TimeWarpEngineering/timewarp-state/issues)
[](https://scorecard.dev/viewer/?uri=github.com/TimeWarpEngineering/timewarp-state)
[](https://www.nuget.org/packages/TimeWarp.State/)
[](https://www.nuget.org/packages/Blazor-State/)
[](https://www.nuget.org/packages/TimeWarp.State/)
[](https://twitter.com/intent/tweet?url=https://github.com/TimeWarpEngineering/timewarp-state)
[](https://dotnet.microsoft.com)
[](https://discord.gg/7F4bS2T)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# TimeWarp.State
**TimeWarp.State** (previously known as Blazor-State) is a fully asynchronous state management library for Blazor applications, leveraging the res pipeline to implement the Flux pattern. It handles both Reducers and Effects consistently using async Handlers, simplifying the management of asynchronous operations throughout your app.
By utilizing the TimeWarp.Mediator pipeline, TimeWarp.State enables a flexible, middleware-driven architecture for managing state, similar to the request-processing pipeline in ASP.NET. This approach allows developers to inject custom behaviors, such as logging, validation, and caching, directly into the state management flow.
In addition to the core library, we offer **[TimeWarp.State.Plus](/Source/TimeWarp.State.Plus)**, which extends the functionality with enhanced middleware, components, and tools to further streamline state management in complex Blazor applications.
## Give a Star! :star:
If you find this project useful, please give it a star. Thanks!
## Getting Started
I recommend the [tutorial](xref:TimeWarp.State:00-StateActionHandler.md) for a step-by-step guide to building a Blazor app with TimeWarp.State.
See full [documentation](https://timewarpengineering.github.io/timewarp-state/).
## Installation
```console
dotnet add package TimeWarp.State
dotnet add package TimeWarp.State.Plus
```
Check out the latest NuGet packages on the [TimeWarp Enterprises NuGet page](https://www.nuget.org/profiles/TimeWarp.Enterprises).
* [TimeWarp.State](https://www.nuget.org/packages/TimeWarp.State/) [](https://www.nuget.org/packages/TimeWarp.State/)
* [TimeWarp.State.Plus](https://www.nuget.org/packages/TimeWarp.State.Plus/) [](https://www.nuget.org/packages/TimeWarp.State.Plus/)
## Releases
View the [Release Notes](https://timewarpengineering.github.io/timewarp-state/ReleaseNotes/Release11.0.0.html) for detailed information on each release.
## Unlicense
[](https://unlicense.org)
This project is licensed under the [Unlicense](https://unlicense.org).
## Contributing
Your contributions are welcome! Before starting any work, please open a [discussion](https://github.com/TimeWarpEngineering/timewarp-state/discussions).
Help with the [documentation](https://timewarpengineering.github.io/timewarp-state/) is also greatly appreciated.
## Contact
If you have an issue and don't receive a timely response, feel free to reach out on our [Discord server](https://discord.gg/A55JARGKKP).
[](https://discord.gg/7F4bS2T)
---
---
title: TimeWarp.Nuru
description: Route-based CLI framework for .NET - batteries included with telemetry, REPL, and shell completion
type: package
latest: 3.0.0-beta.71
stable: 2.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-nuru
---
Route-based CLI framework for .NET - batteries included with telemetry, REPL, and shell completion
| | |
|---|---|
| Latest stable | `2.0.0` |
| Latest prerelease | `3.0.0-beta.71` |
| Downloads | 23,428 |
| Last published | 2026-06-15 |
| Target frameworks | `net10.0` |
## Install
```sh
dotnet add package TimeWarp.Nuru
dotnet add package TimeWarp.Nuru --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Nuru) · [Source](https://github.com/TimeWarpEngineering/timewarp-nuru) · Part of the [timewarp-nuru](/projects/timewarp-nuru/) family
---
# TimeWarp.Nuru
> **Nuru** means "light" in Swahili - illuminating the path to your commands with clarity and simplicity.
## 📦 Installation
```bash
dotnet add package TimeWarp.Nuru
```
## 🚀 Quick Start
TimeWarp.Nuru offers two patterns for defining CLI commands.
Start with the Endpoint DSL for structured apps, or Fluent DSL for quick scripts.
### Endpoint DSL
Define routes as classes with `[NuruRoute]` attributes:
```csharp
using TimeWarp.Nuru;
[NuruRoute("add", Description = "Add two numbers together")]
public sealed class AddCommand : ICommand
{
[Parameter(Order = 0)] public double X { get; set; }
[Parameter(Order = 1)] public double Y { get; set; }
public sealed class Handler : ICommandHandler
{
public ValueTask Handle(AddCommand command, CancellationToken ct)
{
Console.WriteLine($"{command.X} + {command.Y} = {command.X + command.Y}");
return default;
}
}
}
// In your main file:
NuruApp app = NuruApp.CreateBuilder()
.DiscoverEndpoints()
.Build();
return await app.RunAsync(args);
```
### Fluent DSL
Define routes inline with a fluent builder API:
```csharp
using TimeWarp.Nuru;
NuruApp app = NuruApp.CreateBuilder()
.Map("add {x:double} {y:double}")
.WithHandler((double x, double y) => Console.WriteLine($"{x} + {y} = {x + y}"))
.AsCommand()
.Done()
.Build();
return await app.RunAsync(args);
```
```bash
dotnet run -- add 15 25
# Output: 15 + 25 = 40
```
**→ [Full Getting Started Guide](documentation/user/getting-started.md)**
## ✨ Key Features
| Feature | Description | Learn More |
|---------|-------------|------------|
| 🎯 **Web-Style Routing** | Familiar `"deploy {env} --version {tag}"` syntax | [Routing Guide](documentation/user/features/routing.md) |
| 📦 **Endpoint DSL** | Class-based commands with `DiscoverEndpoints()` auto-discovery | [Architecture Choices](documentation/user/guides/architecture-choices.md) |
| 🔧 **Fluent DSL** | Inline routes with `.Map().WithHandler().Done()` chain | [Architecture Choices](documentation/user/guides/architecture-choices.md) |
| 🛡️ **Roslyn Analyzer** | Catch route errors at compile-time | [Analyzer Docs](documentation/user/features/analyzer.md) |
| ⌨️ **Shell Completion** | Tab completion for bash, zsh, PowerShell, fish | [Shell Completion](#-shell-completion) |
| 🤖 **MCP Server** | AI-assisted development with Claude | [MCP Server Guide](documentation/user/tools/mcp-server.md) |
| 📊 **Logging Package** | Zero-overhead structured logging | [Logging Docs](documentation/user/features/logging.md) |
| 🚀 **Native AOT** | Zero warnings, 3.3 MB binaries, instant startup | [Deployment Guide](documentation/user/guides/deployment.md#native-aot-compilation) |
| 🔒 **Type-Safe Parameters** | Automatic type conversion and validation | [Supported Types](documentation/user/reference/supported-types.md) |
| 📖 **Auto-Help** | Generate help from route patterns | [Auto-Help Feature](documentation/user/features/auto-help.md) |
| 🎨 **Rich Terminal** | Colors, tables, panels, rules via [TimeWarp.Terminal](https://github.com/TimeWarpEngineering/timewarp-terminal) | [Terminal Guide](documentation/user/features/terminal-abstractions.md) |
## 📚 Documentation
### Getting Started
- **[Getting Started Guide](documentation/user/getting-started.md)** - Build your first CLI app in 5 minutes
- **[Use Cases](documentation/user/use-cases.md)** - Greenfield apps & progressive enhancement patterns
- **[Architecture Choices](documentation/user/guides/architecture-choices.md)** - Choose Endpoint DSL or Fluent DSL
### Core Features
- **[Routing Patterns](documentation/user/features/routing.md)** - Complete route syntax reference
- **[Roslyn Analyzer](documentation/user/features/analyzer.md)** - Compile-time validation
- **[Logging System](documentation/user/features/logging.md)** - Structured logging setup
- **[Auto-Help](documentation/user/features/auto-help.md)** - Automatic help generation
- **[Output Handling](documentation/user/features/output-handling.md)** - stdout/stderr best practices
- **[Terminal Abstractions](documentation/user/features/terminal-abstractions.md)** - Testable I/O & colored output
### Tools & Deployment
- **[MCP Server](documentation/user/tools/mcp-server.md)** - AI-powered development assistance
- **[Deployment Guide](documentation/user/guides/deployment.md)** - Native AOT, runfiles, distribution
- **[Best Practices](documentation/user/guides/best-practices.md)** - Patterns for maintainable CLIs
### Reference
- **[Performance Benchmarks](documentation/user/reference/performance.md)** - Detailed performance metrics
- **[Supported Types](documentation/user/reference/supported-types.md)** - Complete type reference
- **[API Documentation](documentation/user/reference/)** - Technical reference
## 🎯 Two Powerful Use Cases
### 🆕 Greenfield CLI Applications
Build modern command-line tools from scratch:
```
myapp/
├── calculator.cs # Single runfile - just 5 lines
└── endpoints/
├── add-command.cs
├── factorial-command.cs
└── ...
```
**Endpoint DSL approach** (class-based, organized by file):
```csharp
// In endpoints/add-command.cs
[NuruRoute("add", Description = "Add two numbers")]
public sealed class AddCommand : ICommand
{
[Parameter] public double X { get; set; }
[Parameter] public double Y { get; set; }
public sealed class Handler : ICommandHandler
{
public ValueTask Handle(AddCommand c, CancellationToken ct)
{
Console.WriteLine($"{c.X} + {c.Y} = {c.X + c.Y}");
return default;
}
}
}
```
**Fluent DSL approach** (inline definitions):
```csharp
NuruApp.CreateBuilder()
.Map("deploy {env} --version {tag?}")
.WithHandler((string env, string? tag) => Deploy(env, tag))
.AsCommand()
.Done()
.Build();
```
### 🔄 Progressive Enhancement
Wrap existing CLIs to add auth, logging, or validation:
```csharp
NuruApp app = NuruApp.CreateBuilder(args)
.Map("deploy prod")
.WithHandler(async () =>
{
if (!await ValidateAccess()) return 1;
return await Shell.ExecuteAsync("existing-cli", "deploy", "prod");
})
.AsCommand()
.Done()
.Map("{*args}")
.WithHandler(async (string[] args) => await Shell.ExecuteAsync("existing-cli", args))
.AsCommand()
.Done()
.Build();
```
**→ [Detailed Use Cases with Examples](documentation/user/use-cases.md)**
## 🌟 Working Examples
**[Calculator Samples](samples/02-calculator/)** - Three complete implementations you can run now:
- **[01-calc-endpoints.cs](samples/02-calculator/01-calc-endpoints.cs)** - Endpoint DSL pattern (testable, DI)
- **[02-calc-fluent.cs](samples/02-calculator/02-calc-fluent.cs)** - Fluent DSL approach (inline handlers)
- **[03-calc-mixed.cs](samples/02-calculator/03-calc-mixed.cs)** - Mixed approach (both patterns together)
```bash
./samples/02-calculator/01-calc-endpoints.cs add 10 20 # Endpoint DSL: structured
./samples/02-calculator/02-calc-fluent.cs factorial 5 # Fluent DSL: inline
```
**[AOT Example](samples/05-aot-example/)** - Native AOT compilation with source generators
## ⚡ Performance
| Implementation | Memory | Speed (37 tests) | Binary Size |
|----------------|--------|------------------|-------------|
| Direct (JIT) | ~4 KB | 2.49s | N/A |
| Direct (AOT) | ~4 KB | **0.30s** 🚀 | 3.3 MB |
| Endpoints (AOT) | Moderate | **0.42s** 🚀 | 4.8 MB |
**Native AOT is 88-93% faster than JIT** → [Full Performance Benchmarks](documentation/user/reference/performance.md)
## 🤖 AI-Powered Development
**For AI agents:** Load the built-in [Nuru Skill](skills/nuru/SKILL.md) for instant access to:
- Complete DSL syntax and patterns
- Testing with TestTerminal
- Route examples and type conversion
> 💡 **Tip:** No MCP installation needed - the skill provides all essential patterns.
**For MCP Server:** Install for Claude Code, Roo Code, or Continue:
```bash
dotnet tool install --global TimeWarp.Nuru.Mcp
```
Get instant help:
- Validate route patterns before writing code
- Generate handler code automatically
- Get syntax examples on demand
- Real-time error guidance
**→ [MCP Server Setup Guide](documentation/user/tools/mcp-server.md)**
## ⌨️ Shell Completion
Enable tab completion for your CLI with one line of code:
```csharp
NuruApp app = NuruApp.CreateBuilder(args)
.Map("deploy {env} --version {tag}")
.WithHandler((string env, string tag) => Deploy(env, tag))
.AsCommand()
.Done()
.Map("status")
.WithHandler(() => ShowStatus())
.AsQuery()
.Done()
.EnableStaticCompletion() // ← Add this
.Build();
```
Generate completion scripts for your shell:
```bash
# Bash
./myapp --generate-completion bash >> ~/.bashrc
# Zsh
./myapp --generate-completion zsh >> ~/.zshrc
# PowerShell
./myapp --generate-completion powershell >> $PROFILE
# Fish
./myapp --generate-completion fish > ~/.config/fish/completions/myapp.fish
```
**Supports:**
- ✅ Command completion (`deploy`, `status`)
- ✅ Option completion (`--version`, `--force`)
- ✅ Short option aliases (`-v`, `-f`)
- ✅ All 4 major shells (bash, zsh, PowerShell, fish)
**See [completion-example](samples/15-completion/) for a complete working example.**
## 🤝 Contributing
We welcome contributions! See [CONTRIBUTING.md](CONTRIBUTING.md) for details.
**For Contributors:**
- **[Developer Documentation](documentation/developer/overview.md)** - Architecture and design
- **[Standards](documentation/developer/standards/)** - Coding conventions
## 📄 License
This project is licensed under the Unlicense - see the [license](license) file for details.
---
**Ready to build powerful CLI applications?**
**[Get Started in 5 Minutes](documentation/user/getting-started.md)** • **[View Examples](samples/02-calculator/)** • **[Read the Docs](documentation/user/overview.md)**
---
---
title: TimeWarp.State.Plus
description: TimeWarp.State.Plus extends TimeWarp.State with additional, features, middleware and components to simplify and enhance your Blazor applications.
type: package
latest: 12.0.0-beta.1
stable: 11.0.3
repository: https://github.com/TimeWarpEngineering/timewarp-state
---
TimeWarp.State.Plus extends TimeWarp.State with additional, features, middleware and components to simplify and enhance your Blazor applications.
| | |
|---|---|
| Latest stable | `11.0.3` |
| Latest prerelease | `12.0.0-beta.1` |
| Downloads | 20,893 |
| Last published | 2025-08-20 |
| Target frameworks | `net8.0` |
## Install
```sh
dotnet add package TimeWarp.State.Plus
dotnet add package TimeWarp.State.Plus --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.State.Plus) · [Source](https://github.com/TimeWarpEngineering/timewarp-state) · Part of the [timewarp-state](/projects/timewarp-state/) family
See [TimeWarp.State](/packages/timewarp.state/) for the full documentation of this family.
---
---
title: TimeWarp.Nuru.Analyzers
description: Roslyn analyzers for TimeWarp.Nuru route pattern validation
type: package
latest: 3.0.0-beta.71
stable: none
repository: https://github.com/TimeWarpEngineering/timewarp-nuru
---
Roslyn analyzers for TimeWarp.Nuru route pattern validation
| | |
|---|---|
| Latest prerelease | `3.0.0-beta.71` |
| Stable release | none yet (prerelease only) |
| Downloads | 15,044 |
| Last published | 2026-06-15 |
## Install
```sh
dotnet add package TimeWarp.Nuru.Analyzers --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Nuru.Analyzers) · [Source](https://github.com/TimeWarpEngineering/timewarp-nuru) · Part of the [timewarp-nuru](/projects/timewarp-nuru/) family
See [TimeWarp.Nuru](/packages/timewarp.nuru/) for the full documentation of this family.
---
---
title: TimeWarp.Architecture
description: TimeWarp Architecture Templates
type: package
latest: 2.0.0-beta.2
stable: 1.0.15+6.0.402
repository: https://github.com/TimeWarpEngineering/timewarp-architecture
---
TimeWarp Architecture Templates
| | |
|---|---|
| Latest stable | `1.0.15+6.0.402` |
| Latest prerelease | `2.0.0-beta.2` |
| Downloads | 14,866 |
| Last published | 2026-06-29 |
| Target frameworks | `net9.0` |
## Install
```sh
dotnet add package TimeWarp.Architecture
dotnet add package TimeWarp.Architecture --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Architecture) · [Source](https://github.com/TimeWarpEngineering/timewarp-architecture) · Part of the [timewarp-architecture](/projects/timewarp-architecture/) family
---
[](https://dotnet.microsoft.com)
[](https://github.com/TimeWarpEngineering/timewarp-architecture)
[](https://discord.gg/7F4bS2T)
[](https://github.com/TimeWarpEngineering/timewarp-architecture/actions)
[](https://www.nuget.org/packages/TimeWarp.Architecture/)
[](https://www.nuget.org/packages/TimeWarp.Architecture/)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# TimeWarp Architecture
## timewarp-architecture
### Documentation
https://timewarpengineering.github.io/timewarp-architecture/
### Installation
```console
dotnet new --install TimeWarp.Architecture
```
### Usage
```console
dotnet new timewarp-architecture -n MyTimeWarpApp
```
## Content
The template creates the distributed app projects and their corresponding test projects.
---
---
title: TimeWarp.Nuru.Mcp
description: MCP server for TimeWarp.Nuru providing route validation, syntax documentation, example code, and handler generation for AI-assisted CLI development.
type: package
latest: 3.0.0-beta.71
stable: none
repository: https://github.com/TimeWarpEngineering/timewarp-nuru
---
MCP server for TimeWarp.Nuru providing route validation, syntax documentation, example code, and handler generation for AI-assisted CLI development.
| | |
|---|---|
| Latest prerelease | `3.0.0-beta.71` |
| Stable release | none yet (prerelease only) |
| Downloads | 13,811 |
| Last published | 2026-06-15 |
## Install
```sh
dotnet add package TimeWarp.Nuru.Mcp --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Nuru.Mcp) · [Source](https://github.com/TimeWarpEngineering/timewarp-nuru) · Part of the [timewarp-nuru](/projects/timewarp-nuru/) family
See [TimeWarp.Nuru](/packages/timewarp.nuru/) for the full documentation of this family.
---
---
title: TimeWarp.Mediator
description: Simple, unambitious mediator implementation in .NET
type: package
latest: 13.0.0
stable: 13.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-mediator
---
Simple, unambitious mediator implementation in .NET
| | |
|---|---|
| Latest stable | `13.0.0` |
| Downloads | 10,028 |
| Last published | 2025-08-04 |
| Target frameworks | `net6.0`, `.NETStandard2.0` |
## Install
```sh
dotnet add package TimeWarp.Mediator
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Mediator) · [Source](https://github.com/TimeWarpEngineering/timewarp-mediator) · Part of the [timewarp-mediator](/projects/timewarp-mediator/) family
---
TimeWarp Mediator
=================
[](https://github.com/TimeWarpEngineering/timewarp-mediator/actions)
[](https://www.nuget.org/packages/TimeWarp.Mediator)
[](https://www.nuget.org/packages/TimeWarp.Mediator)
Simple, unambitious mediator implementation in .NET
In-process messaging with no dependencies.
Supports request/response, commands, queries, notifications and events, synchronous and async with intelligent dispatching via C# generic variance.
## About This Fork
TimeWarp.Mediator is a fork of the excellent [MediatR](https://github.com/jbogard/MediatR) library by Jimmy Bogard. We created this fork to:
- ✅ Correct the spelling from "MediatR" to "Mediator"
- ✅ Release under The Unlicense for maximum freedom
- ✅ Maintain full API compatibility with MediatR
- ✅ Add helpful diagnostic tools like `GetPipelineInfo()`
### Migration from MediatR
Migrating from MediatR is straightforward - see our [migration guide](./migration.md) for step-by-step instructions.
---
## Original MediatR

[](https://www.nuget.org/packages/mediatr)
[](https://www.nuget.org/packages/mediatr)
[](https://myget.org/gallery/mediatr-ci)
Simple mediator implementation in .NET
In-process messaging with no dependencies.
Supports request/response, commands, queries, notifications and events, synchronous and async with intelligent dispatching via C# generic variance.
Examples in the [wiki](https://github.com/jbogard/MediatR/wiki).
### Installing TimeWarp.Mediator
You should install [TimeWarp.Mediator with NuGet](https://www.nuget.org/packages/TimeWarp.Mediator):
Install-Package TimeWarp.Mediator
Or via the .NET Core command line interface:
dotnet add package TimeWarp.Mediator
Either commands, from Package Manager Console or .NET Core CLI, will download and install TimeWarp.Mediator and all required dependencies.
### Using Contracts-Only Package
To reference only the contracts for TimeWarp.Mediator, which includes:
- `IRequest` (including generic variants)
- `INotification`
- `IStreamRequest`
Add a package reference to [TimeWarp.Mediator.Contracts](https://www.nuget.org/packages/TimeWarp.Mediator.Contracts)
This package is useful in scenarios where your TimeWarp.Mediator contracts are in a separate assembly/project from handlers. Example scenarios include:
- API contracts
- GRPC contracts
- Blazor
### Registering with `IServiceCollection`
TimeWarp.Mediator supports `Microsoft.Extensions.DependencyInjection.Abstractions` directly. To register various Mediator services and handlers:
```
services.AddMediator(cfg => cfg.RegisterServicesFromAssemblyContaining());
```
or with an assembly:
```
services.AddMediator(cfg => cfg.RegisterServicesFromAssembly(typeof(Startup).Assembly));
```
This registers:
- `IMediator` as transient
- `ISender` as transient
- `IPublisher` as transient
- `IRequestHandler<,>` concrete implementations as transient
- `IRequestHandler<>` concrete implementations as transient
- `INotificationHandler<>` concrete implementations as transient
- `IStreamRequestHandler<>` concrete implementations as transient
- `IRequestExceptionHandler<,,>` concrete implementations as transient
- `IRequestExceptionAction<,>)` concrete implementations as transient
This also registers open generic implementations for:
- `INotificationHandler<>`
- `IRequestExceptionHandler<,,>`
- `IRequestExceptionAction<,>`
To register behaviors, stream behaviors, pre/post processors:
```csharp
services.AddMediator(cfg => {
cfg.RegisterServicesFromAssembly(typeof(Startup).Assembly);
cfg.AddBehavior();
cfg.AddStreamBehavior();
cfg.AddRequestPreProcessor();
cfg.AddRequestPostProcessor();
cfg.AddOpenBehavior(typeof(GenericBehavior<,>));
});
```
With additional methods for open generics and overloads for explicit service types.
## License
TimeWarp Mediator is released under The Unlicense (see `UNLICENSE`). Original MediatR code by Jimmy Bogard is under Apache 2.0 (see `NOTICE`).
---
---
title: TimeWarp.Mediator.Contracts
description: Contracts package for requests, responses, and notifications
type: package
latest: 13.0.0
stable: 13.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-mediator
---
Contracts package for requests, responses, and notifications
| | |
|---|---|
| Latest stable | `13.0.0` |
| Downloads | 9,922 |
| Last published | 2025-08-04 |
| Target frameworks | `.NETStandard2.0` |
## Install
```sh
dotnet add package TimeWarp.Mediator.Contracts
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Mediator.Contracts) · [Source](https://github.com/TimeWarpEngineering/timewarp-mediator) · Part of the [timewarp-mediator](/projects/timewarp-mediator/) family
See [TimeWarp.Mediator](/packages/timewarp.mediator/) for the full documentation of this family.
---
---
title: TimeWarp.Amuru
description: Fluent API for elegant C# scripting with pipeline support
type: package
latest: 1.0.0
stable: 1.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-amuru
---
Fluent API for elegant C# scripting with pipeline support
| | |
|---|---|
| Latest stable | `1.0.0` |
| Downloads | 7,919 |
| Last published | 2026-07-05 |
| Target frameworks | `net10.0` |
## Install
```sh
dotnet add package TimeWarp.Amuru
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Amuru) · [Source](https://github.com/TimeWarpEngineering/timewarp-amuru) · Part of the [timewarp-amuru](/projects/timewarp-amuru/) family
---
[](https://github.com/TimeWarpEngineering/timewarp-amuru)
[](https://github.com/TimeWarpEngineering/timewarp-amuru/actions)
[](https://github.com/TimeWarpEngineering/timewarp-amuru)
[](https://github.com/TimeWarpEngineering/timewarp-amuru/issues)
[](https://github.com/TimeWarpEngineering/timewarp-amuru/issues)
[](https://scorecard.dev/viewer/?uri=github.com/TimeWarpEngineering/timewarp-amuru)
[](https://www.nuget.org/packages/TimeWarp.Amuru/)
[](https://www.nuget.org/packages/TimeWarp.Amuru/)
[](https://twitter.com/intent/tweet?url=https://github.com/TimeWarpEngineering/timewarp-amuru)
[](https://dotnet.microsoft.com)
[](https://discord.gg/7F4bS2T)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# TimeWarp.Amuru
*Amuru means "command" in Swahili*
**TimeWarp.Amuru** is a fluent API library for elegant command-line execution in C#. It transforms shell scripting into a type-safe, IntelliSense-friendly experience with a simple static `Builder()` method, async operations, and shell-like error handling.
Designed for modern C# developers, TimeWarp.Amuru brings the power of shell scripting directly into your C# code. Whether you're building automation tools, DevOps scripts, or integrating command-line tools into your applications, TimeWarp.Amuru provides the elegant, type-safe API you need.
## Why TimeWarp.Amuru?
- **Zero Learning Curve**: If you know C#, you already know how to use TimeWarp.Amuru
- **IntelliSense Everything**: Full IDE support with autocomplete, parameter hints, and documentation
- **Type Safety**: Catch errors at compile-time, not runtime
- **No String Escaping Hell**: Use C# arrays and parameters naturally
- **Native AOT Ready**: Both packages declare and validate AOT/trimming compatibility
- **Built for .NET 10**: Modern C# features and first-class file-based app (runfile) support
- **Script or Library**: Use it in quick scripts or production applications
## Give a Star! :star:
If you find this project useful, please give it a star. Thanks!
## Installation
```bash
# Core library: process execution, mocking, native file operations
dotnet add package TimeWarp.Amuru
# Optional: fluent builders for dotnet/git/fzf plus repo services
dotnet add package TimeWarp.Amuru.Tools --prerelease
```
Or reference in your C# runfile:
```csharp
#:package TimeWarp.Amuru@
```
Both packages share the `TimeWarp.Amuru` namespace — adding the Tools reference lights up `DotNet.*`, `Git.*`, and `Fzf.*` with no code changes.
### Optional: CLI Tools
```bash
# Global CLI tool with additional utilities (private package)
dotnet tool install --global TimeWarp.Ganda --source https://nuget.pkg.github.com/TimeWarpEngineering/index.json
```
See the [Ganda repository](https://github.com/TimeWarpEngineering/timewarp-ganda) for details.
## Quick Start
```csharp
#!/usr/bin/dotnet --
#:package TimeWarp.Amuru
using TimeWarp.Amuru;
using static System.Console;
// Default behavior - stream to console (like bash/PowerShell)
await Shell.Builder("npm").WithArguments("install").RunAsync();
// Capture output when needed
CommandOutput result = await Shell.Builder("git").WithArguments("status").CaptureAsync();
if (result.Success)
{
WriteLine($"Git says: {result.Stdout}");
}
// Stream large files without memory issues
await foreach (string line in Shell.Builder("tail").WithArguments("-f", "/var/log/app.log").StreamStdoutAsync())
{
WriteLine($"Log: {line}");
}
// Chain commands with pipelines
CommandOutput found = await Shell.Builder("find")
.WithArguments(".", "-name", "*.cs")
.Pipe("grep", "async")
.CaptureAsync();
WriteLine($"Found {found.GetLines().Length} async lines");
// Work with CommandOutput
CommandOutput output = await Shell.Builder("docker").WithArguments("ps").CaptureAsync();
WriteLine($"Exit code: {output.ExitCode}");
WriteLine($"Success: {output.Success}");
WriteLine($"Stdout: {output.Stdout}");
WriteLine($"Stderr: {output.Stderr}");
WriteLine($"Combined: {output.Combined}");
// Use the fluent builder API for complex commands
CommandOutput log = await Shell.Builder("git")
.WithArguments("log", "--oneline", "-n", "10")
.WithWorkingDirectory("/my/repo")
.CaptureAsync(cancellationToken);
// Provide standard input to commands
CommandOutput grepResult = await Shell.Builder("grep")
.WithArguments("pattern")
.WithStandardInput("line1\nline2 with pattern\nline3")
.CaptureAsync();
// Full interactive mode for stream-based tools (fzf, REPLs)
await Shell.Builder("fzf").PassthroughAsync();
// TUI applications (vim, nano, edit) need true TTY passthrough
await Shell.Builder("vim")
.WithArguments("myfile.txt")
.TtyPassthroughAsync();
```
### Tool Builders (TimeWarp.Amuru.Tools)
```csharp
// Global dotnet options
CommandOutput sdks = await DotNet.WithListSdks().CaptureAsync();
CommandOutput version = await DotNet.WithVersion().CaptureAsync();
// Base builder for custom arguments
CommandOutput custom = await DotNet.Builder()
.WithArguments("--list-runtimes")
.CaptureAsync();
// Build and test with streaming output
await DotNet.Build()
.WithConfiguration("Release")
.RunAsync();
await DotNet.Test()
.WithFilter("Category=Unit")
.RunAsync();
// Git operations with typed results
string? repoRoot = Git.FindRoot();
string porcelain = await Git.WorktreeListPorcelainAsync("/my/repo");
IReadOnlyList worktrees = Git.ParseWorktreeList(porcelain);
// Interactive selection with Fzf
string selectedFile = await Fzf.Builder()
.FromInput("file1.txt", "file2.txt", "file3.txt")
.WithPreview("cat {}")
.SelectAsync();
```
## Key Features
- **Shell-Like Default**: `RunAsync()` streams to console just like bash/PowerShell
- **Explicit Capture**: `CaptureAsync()` for when you need to process output
- **Memory-Efficient Streaming**: `IAsyncEnumerable` for large data without buffering
- **One Result Type**: `CommandOutput` with Stdout, Stderr, Combined, ExitCode, Success, and RunTime — from every execution mode
- **Shell-Like Error Handling**: non-zero exit codes are values, not exceptions; strict validation is one opt-in call away
- **Built-In Command Mocking**: `CommandMock` with strict-by-default matching — tests can never silently run real commands
- **Pipeline Support**: Chain commands with Unix-like pipe semantics
- **Standard Input Support**: Provide stdin to commands with `.WithStandardInput()`
- **NO CACHING Philosophy**: Like shells, commands run fresh every time
- **Cancellation Support**: Full CancellationToken support throughout
- **Cross-Platform**: Works on Windows, Linux, and macOS (including `.cs` script execution on Windows via the dotnet host)
- **Interactive Commands**: `PassthroughAsync()` for stream-based tools, `TtyPassthroughAsync()` for TUI apps (vim, nano), `SelectAsync()` for selection tools
- **.NET 10 Script Support**: AppContext extensions and ScriptContext for file-based apps
## Output Handling
### Core API Methods
```csharp
// RunAsync() - Default shell behavior, streams to console
await Shell.Builder("npm").WithArguments("install").RunAsync();
// Returns: exit code (int)
// CaptureAsync() - Silent execution with full output capture
CommandOutput result = await Shell.Builder("git").WithArguments("status").CaptureAsync();
// Returns: CommandOutput; no console output
// RunAndCaptureAsync() - Stream to console AND capture
CommandOutput logged = await Shell.Builder("dotnet").WithArguments("build").RunAndCaptureAsync();
// PassthroughAsync() - Stream-based interactive tools (fzf, REPLs)
CommandOutput fzfResult = await Shell.Builder("fzf").PassthroughAsync();
// TtyPassthroughAsync() - True TTY for TUI applications (vim, nano, edit)
CommandOutput vimResult = await Shell.Builder("vim").WithArguments("file.txt").TtyPassthroughAsync();
// SelectAsync() - Selection tools (shows UI on stderr, captures stdout selection)
string selected = await Shell.Builder("fzf").SelectAsync();
```
### The CommandOutput Type
```csharp
CommandOutput output = await Shell.Builder("docker").WithArguments("ps").CaptureAsync();
// Access individual streams
Console.WriteLine($"Stdout: {output.Stdout}");
Console.WriteLine($"Stderr: {output.Stderr}");
Console.WriteLine($"Combined: {output.Combined}"); // Captured in arrival order
// Check status
Console.WriteLine($"Exit code: {output.ExitCode}");
Console.WriteLine($"Success: {output.Success}"); // ExitCode == 0
Console.WriteLine($"Runtime: {output.RunTime}");
// Line processing (interior blank lines preserved; no trailing empty entry)
foreach (string line in output.GetLines())
{
ProcessLine(line);
}
// Or line-level access with source-stream metadata
foreach (OutputLine line in output.OutputLines)
{
Console.WriteLine($"{(line.IsError ? "ERR" : "OUT")}: {line.Text}");
}
// Pretty-print a result with status coloring
output.WriteToConsole();
```
### Streaming Large Data
```csharp
// Stream lines as they arrive (no buffering)
await foreach (string line in Shell.Builder("tail")
.WithArguments("-f", "/var/log/app.log")
.StreamStdoutAsync(cancellationToken))
{
Console.WriteLine($"Log: {line}");
}
```
### Method Comparison
| Method | Console Output | Captures | Returns | Primary Use Case |
|--------|---------------|----------|---------|------------------|
| `RunAsync()` | ✅ Real-time | ❌ | Exit code | Default scripting |
| `CaptureAsync()` | ❌ Silent | ✅ All streams | CommandOutput | Process output |
| `RunAndCaptureAsync()` | ✅ Real-time | ✅ All streams | CommandOutput | Logging + capture |
| `PassthroughAsync()` | ✅ Piped | ❌ | CommandOutput | Stream-based interactive |
| `TtyPassthroughAsync()` | ✅ TTY | ❌ | CommandOutput | TUI apps (vim, nano) |
| `SelectAsync()` | ✅ UI only | ✅ Selection | string | Selection tools |
| `StreamStdoutAsync()` | ❌ | ✅ As stream | IAsyncEnumerable | Large data |
### Design Philosophy: NO CACHING
TimeWarp.Amuru intentionally does NOT cache command results:
```csharp
// Shells don't cache - neither do we
await Shell.Builder("date").RunAsync(); // Shows current time
await Shell.Builder("date").RunAsync(); // Shows NEW current time
// If you need caching, it's trivial in C#:
private static CommandOutput? cachedResult;
CommandOutput result = cachedResult ??= await Shell.Builder("expensive-command").CaptureAsync();
```
## Error Handling
TimeWarp.Amuru handles failure the way shells do: **a non-zero exit code is a value you inspect, not an exception**.
### Default Behavior (Never Throws on Exit Codes)
```csharp
CommandOutput result = await Shell.Builder("ls").WithArguments("/nonexistent").CaptureAsync();
if (!result.Success)
{
Console.WriteLine($"Command failed with exit code: {result.ExitCode}");
Console.WriteLine($"Error: {result.Stderr}");
}
```
### Strict Validation (Opt-in Throwing)
```csharp
// Throws on any non-zero exit code
await Shell.Builder("git")
.WithArguments("push")
.WithZeroExitCodeValidation()
.RunAsync();
```
### Commands That Never Ran
An empty/invalid command or a failed pipeline composition never throws, but it is never mistaken for success either — it reports `CommandResult.NeverRanExitCode` (-1):
```csharp
CommandOutput result = await Shell.Builder("").CaptureAsync();
// result.Success == false, result.ExitCode == CommandResult.NeverRanExitCode
```
Note: a **missing executable** (e.g. a typo'd command name) still throws at execution time — that is an environment error, not an exit code.
### Cancellation and Timeouts
```csharp
// With explicit cancellation token
using CancellationTokenSource cts = new(TimeSpan.FromSeconds(30));
await Shell.Builder("long-running-command").RunAsync(cts.Token);
```
## Testing and Mocking
### CommandMock (Recommended)
`CommandMock` intercepts command execution in-process — no mock executables needed. It is **strict by default**: a command with no matching setup throws instead of silently running the real thing.
```csharp
using TimeWarp.Amuru.Testing;
using (CommandMock.Enable())
{
CommandMock.Setup("git", "status")
.Returns("On branch main\nnothing to commit");
CommandOutput output = await Shell.Builder("git").WithArguments("status").CaptureAsync();
// output.Stdout == "On branch main\nnothing to commit" — no real git ran
CommandMock.VerifyCalled("git", "status");
}
// Simulate failures and exceptions
using (CommandMock.Enable())
{
CommandMock.Setup("git", "push").ReturnsError("remote: Permission denied", 128);
CommandMock.Setup("flaky-tool").Throws(new TimeoutException("simulated"));
CommandMock.Setup("slow-tool").Delays(TimeSpan.FromSeconds(2));
// ...
}
// Mixed mocked + real commands (opt out of strict mode)
using (CommandMock.Enable(MockBehavior.Loose))
{
CommandMock.Setup("deploy-tool").Returns("deployed");
// unmocked commands fall through to real execution
}
```
Mocking is scoped per async context (parallel tests stay isolated) and covers every execution mode — run, capture, streaming, select, and passthrough. `Pipe` compositions are the documented exception (use loose mode).
### CliConfiguration (Path Overrides)
For cases where you want a real replacement executable, redirect a command process-wide:
```csharp
CliConfiguration.SetCommandPath("fzf", "/tmp/mock-bin/fzf");
// ... code using fzf now runs the replacement ...
CliConfiguration.Reset();
```
API: `SetCommandPath`, `ClearCommandPath`, `Reset`, `HasCustomPath`, `AllCommandPaths`. Overrides are process-global by design — use `CommandMock` for per-test isolation.
## .NET 10 File-Based App Support
TimeWarp.Amuru provides specialized support for .NET 10's file-based apps (single-file C# scripts):
- **AppContext Extensions** — `AppContext.EntryPointFilePath()` / `EntryPointFileDirectoryPath()` without magic strings
- **ScriptContext** — scoped working-directory management with cleanup on dispose or process exit (contexts nest safely)
- **`.cs` as a command** — `Shell.Builder("script.cs")` runs another runfile (shebang on Unix, dotnet host on Windows)
📖 **[See the documentation](documentation/developer/how-to-guides/)** for detailed usage guides and examples.
## Architecture
- **Static Entry Point**: Minimal ceremony with `Shell.Builder()` / `Shell.Run()`
- **Two Packages, One Namespace**: `TimeWarp.Amuru` (stable core) and `TimeWarp.Amuru.Tools` (tool builders, own release cadence)
- **Shell Semantics**: exit codes are values; composition never throws; nothing is cached
- **Predictable Error Handling**: never-ran, non-zero-exit, and environment failures are all distinguishable
- **Opt-in Complexity**: Advanced features available when needed
See our [Architectural Decision Records](documentation/conceptual/architectural-decision-records/overview.md) for detailed design rationale.
## Documentation
- **[Documentation overview](documentation/overview.md)** - Entry point to conceptual, developer, and user docs
- **[Migration Guide](analysis/migration-guide.md)** - Guide for migrating from older versions
- **[command-extensions.cs](source/timewarp-amuru/core/command-extensions.cs)** - Collocated command construction design documentation
- **[command-result.cs](source/timewarp-amuru/core/command-result.cs)** - Collocated command execution design documentation
- **[Samples](samples/)** - Compiling example scripts referenced against the live source
## Unlicense
[](https://unlicense.org)
This project is licensed under the [Unlicense](https://unlicense.org).
## Related Packages
- **[TimeWarp.Amuru.Tools](https://www.nuget.org/packages/TimeWarp.Amuru.Tools/)** - Fluent dotnet/git/fzf builders and repo services on top of this library
- **[TimeWarp.Multiavatar](https://www.nuget.org/packages/TimeWarp.Multiavatar/)** - Avatar generation library ([repository](https://github.com/TimeWarpEngineering/timewarp-multiavatar))
- **[TimeWarp.Ganda](https://github.com/TimeWarpEngineering/timewarp-ganda)** - Shell toolkit CLI (private, separate repository)
## Contributing
Your contributions are welcome! Before starting any work, please open a [discussion](https://github.com/TimeWarpEngineering/timewarp-amuru/discussions).
See our [Kanban board](kanban/overview.md) for current development tasks and priorities.
## Contact
If you have an issue and don't receive a timely response, feel free to reach out on our [Discord server](https://discord.gg/A55JARGKKP).
[](https://discord.gg/7F4bS2T)
---
---
title: TimeWarp.State.Policies
description: Policies for TimeWarp State management library
type: package
latest: 12.0.0-beta.1
stable: 11.0.3
repository: https://github.com/TimeWarpEngineering/timewarp-state
---
Policies for TimeWarp State management library
| | |
|---|---|
| Latest stable | `11.0.3` |
| Latest prerelease | `12.0.0-beta.1` |
| Downloads | 5,839 |
| Last published | 2025-08-20 |
| Target frameworks | `net8.0` |
## Install
```sh
dotnet add package TimeWarp.State.Policies
dotnet add package TimeWarp.State.Policies --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.State.Policies) · [Source](https://github.com/TimeWarpEngineering/timewarp-state) · Part of the [timewarp-state](/projects/timewarp-state/) family
See [TimeWarp.State](/packages/timewarp.state/) for the full documentation of this family.
---
---
title: TimeWarp.Build.Tasks
description: MSBuild tasks for TimeWarp projects including git metadata injection and build automation
type: package
latest: 1.0.0
stable: 1.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-build-tasks
---
MSBuild tasks for TimeWarp projects including git metadata injection and build automation
| | |
|---|---|
| Latest stable | `1.0.0` |
| Downloads | 5,449 |
| Last published | 2025-10-14 |
## Install
```sh
dotnet add package TimeWarp.Build.Tasks
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Build.Tasks) · [Source](https://github.com/TimeWarpEngineering/timewarp-build-tasks)
---
[](https://github.com/TimeWarpEngineering/timewarp-build-tasks)
[](https://github.com/TimeWarpEngineering/timewarp-build-tasks)
[](https://github.com/TimeWarpEngineering/timewarp-build-tasks/issues)
[](https://github.com/TimeWarpEngineering/timewarp-build-tasks/issues)
[](https://www.nuget.org/packages/TimeWarp.Build.Tasks/)
[](https://www.nuget.org/packages/TimeWarp.Build.Tasks/)
[](https://twitter.com/intent/tweet?url=https://github.com/TimeWarpEngineering/timewarp-build-tasks)
[](https://dotnet.microsoft.com)
[](https://discord.gg/7F4bS2T)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# TimeWarp.Build.Tasks
**TimeWarp.Build.Tasks** is an MSBuild tasks library that provides build-time automation for .NET projects. The library automatically injects git metadata (commit hash and timestamp) into your assemblies at build time, enabling better traceability and versioning in production deployments.
This build-time dependency integrates seamlessly into your build pipeline without adding runtime overhead, making it ideal for CI/CD workflows and production builds where tracking exact source versions is critical.
## Give a Star! :star:
If you find this project useful, please give it a star. Thanks!
## Features
- **Automatic Git Metadata Injection** - Embeds commit hash and timestamp into assembly metadata
- **Build-Time Only** - No runtime dependencies or performance impact
- **Transitive Support** - Automatically applied to projects that reference packages using this library
- **Configurable** - Can be disabled per-project with `TimeWarpEnableGitMetadata=false`
- **Fallback Handling** - Gracefully handles non-git repositories without breaking builds
## Installation
```console
dotnet add package TimeWarp.Build.Tasks
```
Check out the latest NuGet packages on the [TimeWarp Enterprises NuGet page](https://www.nuget.org/profiles/TimeWarp.Enterprises).
* [TimeWarp.Build.Tasks](https://www.nuget.org/packages/TimeWarp.Build.Tasks/) [](https://www.nuget.org/packages/TimeWarp.Build.Tasks/)
## Usage
Once installed, git metadata is automatically injected into your assemblies during build. Access the metadata at runtime:
```csharp
using System.Reflection;
var assembly = typeof(Program).Assembly;
var commitHash = assembly.GetCustomAttributes()
.FirstOrDefault(a => a.Key == "CommitHash")?.Value;
var commitDate = assembly.GetCustomAttributes()
.FirstOrDefault(a => a.Key == "CommitDate")?.Value;
Console.WriteLine($"Built from commit: {commitHash}");
Console.WriteLine($"Commit date: {commitDate}");
```
### Disabling Git Metadata
To disable automatic git metadata injection for a specific project:
```xml
false
```
## Documentation
See full [documentation](https://timewarpengineering.github.io/timewarp-build-tasks/).
## Unlicense
[](https://unlicense.org)
This project is licensed under the [Unlicense](https://unlicense.org).
## Contributing
Your contributions are welcome! Before starting any work, please open a [discussion](https://github.com/TimeWarpEngineering/timewarp-build-tasks/discussions).
Help with the [documentation](https://timewarpengineering.github.io/timewarp-build-tasks/) is also greatly appreciated.
## Contact
If you have an issue and don't receive a timely response, feel free to reach out on our [Discord server](https://discord.gg/A55JARGKKP).
[](https://discord.gg/7F4bS2T)
---
---
title: TimeWarp.Fixie
description: The TimeWarp Fixie testing convention
type: package
latest: 3.1.0+9.0.300
stable: 3.1.0+9.0.300
repository: https://github.com/TimeWarpEngineering/timewarp-fixie
---
The TimeWarp Fixie testing convention
| | |
|---|---|
| Latest stable | `3.1.0+9.0.300` |
| Downloads | 5,157 |
| Last published | 2025-06-04 |
| Target frameworks | `net9.0` |
## Install
```sh
dotnet add package TimeWarp.Fixie
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Fixie) · [Source](https://github.com/TimeWarpEngineering/timewarp-fixie)
---
[](https://dotnet.microsoft.com)
[](https://github.com/TimeWarpEngineering/timewarp-fixie)
[](https://discord.gg/7F4bS2T)
[](https://www.nuget.org/packages/TimeWarp.Fixie/)
[](https://www.nuget.org/packages/TimeWarp.Fixie/)
[](https://github.com/TimeWarpEngineering/timewarp-fixie/issues)
[](https://github.com/TimeWarpEngineering/timewarp-fixie)
[](https://unlicense.org)
[](https://twitter.com/intent/tweet?url=https://github.com/TimeWarpEngineering/timewarp-fixie)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# timewarp-fixie

[Fixie](https://github.com/fixie/fixie/wiki) is a dotnet test framework similar to NUnit and xUnit, but with an emphasis on low-ceremony defaults and flexible customizations.
TimeWarp-fixie is a project that uses conventions to simplify using Fixie even further.
## Feature overview
* Dependency Injection support for test cases.
* No need to decorate test methods with [Test] attributes. Public methods are test cases by default.
* Skip - can mark tests to be skipped.
* Tags - Add tags to your tests and filter runs based on the tag.
* Inputs - Allow for parameterized tests. (similar to how "Theory" works in xUnit)
* Lifecycle Methods - if the `Setup` or `Cleanup` methods are found on the test class they will be executed appropriately.
* NotTest - Can mark methods with `NotTest` attribute if they are not tests.
* Filter tests by name
* Filter tests by Tags
## Give a Star! :star:
If you like or are using this project please give it a star. Thank you!
## Installation
You can see the latest NuGet packages from the official [TimeWarp NuGet page](https://www.nuget.org/profiles/TimeWarp.Enterprises).
* [timewarp-fixie](https://www.nuget.org/packages/TimeWarp.Fixie/) [](https://www.nuget.org/packages/TimeWarp.Fixie/)
## Usage
### Creating a New Test Project
Create a new test project:
```console
dotnet new classlib -n MyProject.Tests
```
Add NuGet packages to the project:
```console
dotnet add package TimeWarp.Fixie
dotnet add package Fixie.TestAdapter
```
Create a dotnet tool manifest:
```console
dotnet new tool-manifest
```
Add Fixie.Console to the manifest:
```console
dotnet tool install Fixie.Console
```
### Configuring Testing Convention
Inside your Fixie project, create a class that inherits from `Fixie.Conventions.TestingConvention`:
```csharp
class TestingConvention : TimeWarp.Fixie.TestingConvention { }
```
This will use the `TimeWarp.Fixie` convention.
### Creating a Sample Test
First, add Shouldly (you could use basic Asserts or any other assertion library):
```csharp
dotnet add package Shouldly
```
Create a sample test class named `ConventionTests.cs`:
```csharp
namespace ConventionTest_;
using Shouldly;
using TimeWarp.Fixie;
[TestTag(TestTags.Fast)]
public class SimpleNoApplicationTest_Should_
{
public static void AlwaysPass() => true.ShouldBeTrue();
[Skip("Demonstrates skip attribute")]
public static void SkipExample() => true.ShouldBeFalse();
[TestTag(TestTags.Fast)]
public static void TagExample() => true.ShouldBeTrue();
[Input(5, 3, 2)]
[Input(8, 5, 3)]
public static void Subtract(int x, int y, int expectedDifference)
{
int result = x - y;
result.ShouldBe(expectedDifference);
}
}
```
### Executing the Tests
```console
dotnet fixie
```
## Features
### Dependency Injection
Tests are instantiated from the dependency injection container set up for tests, so you can use the same pattern for testing as for production apps.
### Configuring Services for the Execution Phase
To customize the services used in the execution phase, inherit from `TestingConvention` and override the service configuration:
```csharp
namespace TimeWarp.Architecture.Testing;
public class TimeWarpTestingConvention : TestingConvention
{
public TimeWarpTestingConvention() : base(ConfigureAdditionalServicesCallback) { }
private static void ConfigureAdditionalServicesCallback(ServiceCollection serviceCollection)
{
Console.WriteLine("ConfigureAdditionalServices");
serviceCollection
.AddSingleton()
.AddSingleton()
.AddSingleton>()
.AddSingleton();
}
}
```
### Class-Specific Service Configuration
You can configure services specific to individual test classes by adding a static `ConfigureServices` method to your test class. This allows different test classes to use different mock implementations:
```csharp
public class UserServiceTests
{
private readonly IUserRepository UserRepository;
public UserServiceTests(IUserRepository userRepository)
{
UserRepository = userRepository;
}
// Configure services specific to this test class
public static void ConfigureServices(IServiceCollection services)
{
services.AddScoped();
services.AddScoped();
}
public void Should_Create_User()
{
// Test implementation using MockUserRepository
}
}
public class OrderServiceTests
{
private readonly IUserRepository UserRepository;
public OrderServiceTests(IUserRepository userRepository)
{
UserRepository = userRepository;
}
// Different mocks for this test class
public static void ConfigureServices(IServiceCollection services)
{
services.AddScoped();
services.AddScoped();
}
public void Should_Process_Order()
{
// Test implementation using FakeUserRepository
}
}
```
### No Need to Decorate Test Methods with [Test] Attributes
Public methods are test cases by convention:
```csharp
// Xunit style
[Test] // <==== Not needed with TimeWarp Fixie Convention
public void SomeTest()
{
Assert.Fail();
}
```
```csharp
// TimeWarp Fixie Convention: all public methods are tests
public void SomeTest()
{
Assert.Fail();
}
```
### Skip - Mark Tests to Be Skipped
```csharp
[Skip("Reason for skipping")]
public static void SkipExample() => true.Should().BeFalse();
```
### Tags
You can add tags to any of your tests. We include some in the `TestTags` static class, but they are just strings, so you can add whatever you like:
```csharp
[TestTag(TestTags.Fast)]
[TestTag("Bug123")]
public static void TagExample() => true.Should().BeTrue();
```
### Parameterized Tests
Similar to how xUnit uses `[Theory]`, you can run a test for each set of parameters:
```csharp
[Input(5, 3, 2)]
[Input(8, 5, 3)]
public static void Subtract(int aX, int aY, int aExpectedDifference)
{
int result = aX - aY;
result.Should().Be(aExpectedDifference);
}
```
### Lifecycle Methods
If the `Setup` or `Cleanup` methods are found on the test class, they will be executed appropriately for each test:
```csharp
public class LifecycleExamples
{
public static void AlwaysPass() => true.Should().BeTrue();
[Input(5, 3, 2)]
[Input(8, 5, 3)]
public static void Subtract(int aX, int aY, int aExpectedDifference)
{
// Will run lifecycles around each Input
int result = aX - aY;
result.Should().Be(aExpectedDifference);
}
public static void Setup() => Console.WriteLine("Sample Setup");
public static void Cleanup() => Console.WriteLine("Sample Cleanup");
}
```
### NotTest
If you have a class that needs to be public but does not contain tests, you can mark it as such with the `[NotTest]` attribute. For example:
```csharp
[NotTest]
[AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]
public class NotTest : Attribute { }
```
### Filtering Tests by Name
From Fixie's [docs](https://github.com/fixie/fixie/wiki/dotnet-fixie#filtering-with---tests):
The optional argument `--tests` (abbreviated `-t`) lets you specify which tests to run.
**Run a single test by full name:**
```console
dotnet fixie --tests Full.Namespace.MyTestClass.MyTestMethod
```
**Run tests with implicit wildcard (most test name prefixes are similar):**
```console
dotnet fixie --tests MyTestClass.MyTestMethod
```
**Run tests with explicit wildcard (`*` matches any sequence of zero or more characters):**
```console
dotnet fixie --tests MyTest*.TestMethod*
```
**Run an entire test class:**
```console
dotnet fixie --tests MyTestClass.*
```
**Leveraging PascalCase naming convention for partial matches:**
```console
dotnet fixie --tests MyTestClass.Should_Create_User
```
---
---
title: TimeWarp.Terminal
description: Terminal abstractions and widgets for console applications - IConsole, ITerminal, panels, tables, rules, and ANSI color support
type: package
latest: 1.0.0
stable: 1.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-terminal
---
Terminal abstractions and widgets for console applications - IConsole, ITerminal, panels, tables, rules, and ANSI color support
| | |
|---|---|
| Latest stable | `1.0.0` |
| Downloads | 4,646 |
| Last published | 2026-07-03 |
| Target frameworks | `net10.0` |
## Install
```sh
dotnet add package TimeWarp.Terminal
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Terminal) · [Source](https://github.com/TimeWarpEngineering/timewarp-terminal)
---
# TimeWarp.Terminal
Terminal abstractions and widgets for console applications - IConsole, ITerminal, panels, tables, rules, and ANSI color support.
## Installation
```bash
dotnet add package TimeWarp.Terminal
```
## Quick Start
```csharp
using TimeWarp.Terminal;
// Use the static Terminal class (Console-compatible API)
Terminal.WriteLine("Hello, World!".Green());
Terminal.WriteLine("Warning!".Yellow().Bold());
// Or get a terminal instance — all Write methods return ITerminal for fluent chaining
ITerminal terminal = TimeWarpTerminal.Default;
terminal
.WritePanel("Important message", "Notice")
.WriteRule("Section")
.WriteTable(t => t
.AddColumn("Name")
.AddColumn("Value")
.AddRow("Status", "OK".Green()))
.WriteLine("Done!");
```
## Static Terminal API
The `Terminal` static class provides a Console-compatible API for easy migration:
```csharp
using static TimeWarp.Terminal.Terminal;
// Direct replacement for Console methods
WriteLine("Hello, World!");
WriteErrorLine("Error occurred!");
string? input = ReadLine();
Clear();
// Properties
int width = WindowWidth;
bool interactive = IsInteractive;
bool colorSupport = SupportsColor;
// Cursor operations
SetCursorPosition(10, 5);
var (left, top) = GetCursorPosition();
```
### Testing with Static Terminal
Use `TestTerminalContext` to redirect the static `Terminal` class in tests:
```csharp
using TestTerminal terminal = new();
using IDisposable scope = TestTerminalContext.Use(terminal);
Terminal.WriteLine("Hello");
terminal.OutputContains("Hello").ShouldBeTrue();
```
The scope is async-context isolated - each test flow sees only its own `TestTerminal`, so parallel tests never interfere with each other, and the global terminal is never mutated. Disposing the scope restores the previous context automatically.
For serial tests you can also swap `Terminal.Instance` directly, but remember to restore it:
```csharp
using TestTerminal testTerminal = new();
Terminal.Instance = testTerminal;
Terminal.WriteLine("test output");
Assert.Contains("test output", testTerminal.Output);
// Restore after test
Terminal.Instance = TimeWarpTerminal.Default;
```
## Interfaces
### IConsole
Basic console I/O abstraction for testable console applications.
```csharp
public interface IConsole
{
IConsole Write(string message);
IConsole WriteLine(string? message = null);
Task WriteLineAsync(string? message = null);
IConsole WriteErrorLine(string? message = null);
Task WriteErrorLineAsync(string? message = null);
string? ReadLine();
}
```
### ITerminal
Extended terminal interface with cursor control, colors, and hyperlinks.
```csharp
public interface ITerminal : IConsole
{
new ITerminal Write(string message);
new ITerminal WriteLine(string? message = null);
new ITerminal WriteErrorLine(string? message = null);
ConsoleKeyInfo ReadKey(bool intercept);
void SetCursorPosition(int left, int top);
(int Left, int Top) GetCursorPosition();
int WindowWidth { get; }
bool IsInteractive { get; }
bool SupportsColor { get; }
bool SupportsHyperlinks { get; }
void Clear();
}
```
## Implementations
| Class | Description |
|-------|-------------|
| `TimeWarpTerminal` | Production `ITerminal` with full terminal capabilities |
| `TimeWarpConsole` | Production `IConsole` wrapping `System.Console` |
| `TestTerminal` | Test implementation with captured output and scripted input |
| `TestConsole` | Simpler test implementation for basic I/O testing |
### Testing Example
```csharp
using TestTerminal terminal = new();
// Queue input for ReadLine
terminal = new TestTerminal("line1\nline2");
// Queue keys for ReadKey
terminal.QueueKey(ConsoleKey.Enter);
terminal.QueueKeys("hello");
terminal.QueueLine("complete line");
// Run code that uses ITerminal
myCommand.Execute(terminal);
// Verify output
Assert.Contains("expected text", terminal.Output);
Assert.Contains("error message", terminal.ErrorOutput);
```
## Widgets
### Panel
Bordered panel with optional header and content.
```csharp
// Simple panel
terminal.WritePanel("This is important information");
// Panel with header
terminal.WritePanel("Content here", "Notice");
// Fluent builder with full options
terminal.WritePanel
(
panel =>
panel
.Header("Configuration".Cyan().Bold())
.Content("Setting: value")
.Border(BorderStyle.Rounded)
.BorderColor(AnsiColors.Cyan)
.Padding(2, 1)
.Width(60)
.WordWrap(true)
);
```
**Border Styles:** `Rounded`, `Square`, `Doubled`, `Heavy`, `None`
### Table
Formatted table with columns, alignment, and styling.
```csharp
// Simple table
terminal.WriteTable
(
t => t
.AddColumn("Name")
.AddColumn("Value", Alignment.Right)
.AddRow("CPU", "45%")
.AddRow("Memory", "2.1 GB")
);
// Full-featured table
terminal.WriteTable(t => t
.AddColumn("Package")
.AddColumn("Downloads", Alignment.Right)
.AddColumn(new TableColumn("Path") { TruncateMode = TruncateMode.Start })
.AddRow("GuardClauses", "12M", "/home/user/packages/guard")
.Border(BorderStyle.Rounded)
.BorderColor(AnsiColors.Cyan)
.Expand()); // tables shrink to fit the terminal automatically
terminal.WriteTable(table);
```
**Alignment:** `Left` (default), `Right`, `Center`
**TruncateMode:** `End` (default), `Start`, `Middle`
### Rule
Horizontal rule with optional centered title.
```csharp
// Simple rule
terminal.WriteRule();
// Rule with title
terminal.WriteRule("Section Title");
// Styled rule
terminal.WriteRule("Results".Cyan().Bold());
// Fluent builder
terminal.WriteRule(rule => rule
.Title("Configuration")
.Style(LineStyle.Doubled)
.Color(AnsiColors.Cyan));
```
**Line Styles:** `Thin`, `Doubled`, `Heavy`
## ANSI Colors
Extension methods for colored and styled console output.
```csharp
// Foreground colors
terminal.WriteLine("Success!".Green());
terminal.WriteLine("Warning!".Yellow());
terminal.WriteLine("Error!".Red());
// Chained styles
terminal.WriteLine("Important".Red().Bold().Underline());
// Background colors
terminal.WriteLine("Highlighted".OnYellow());
terminal.WriteLine("Inverted".Black().OnWhite());
```
### Available Colors
**Standard:** `Black`, `Red`, `Green`, `Yellow`, `Blue`, `Magenta`, `Cyan`, `White`, `Gray`
**Bright:** `BrightRed`, `BrightGreen`, `BrightYellow`, `BrightBlue`, `BrightMagenta`, `BrightCyan`, `BrightWhite`
### Styles
`Bold()`, `Dim()`, `Italic()`, `Underline()`, `Strikethrough()`
### Background Colors
`OnBlack()`, `OnRed()`, `OnGreen()`, `OnYellow()`, `OnBlue()`, `OnMagenta()`, `OnCyan()`, `OnWhite()`
## ConsoleColor Support
Use `ConsoleColor` enum values for color output without needing ANSI escape codes directly. This provides a Console-compatible API for colored output.
```csharp
// Single foreground color
Terminal.WriteLine("Error!", ConsoleColor.Red);
Terminal.WriteLine("Success!", ConsoleColor.Green);
Terminal.WriteLine("Warning!", ConsoleColor.Yellow);
// Foreground and background colors
Terminal.WriteLine("Highlighted", ConsoleColor.Black, ConsoleColor.Yellow);
Terminal.WriteLine("Inverted", ConsoleColor.White, ConsoleColor.Black);
// Error output with color
Terminal.WriteErrorLine("Error: File not found", ConsoleColor.Red);
// Write without newline
Terminal.Write("Loading...", ConsoleColor.Cyan);
// Widgets with colors
Terminal.WriteTable(table => table
.AddColumn("Name")
.AddColumn("Value")
.AddRow("Status", "OK"),
ConsoleColor.White, ConsoleColor.DarkBlue);
Terminal.WritePanel("Important content", "Notice",
ConsoleColor.White, ConsoleColor.DarkBlue);
```
### Supported Colors
All `ConsoleColor` values are mapped to their ANSI equivalents:
**Foreground:** `Black`, `Red`, `Green`, `Yellow`, `Blue`, `Magenta`, `Cyan`, `White`, `Gray`, `DarkGray`, `DarkRed`, `DarkGreen`, `DarkYellow`, `DarkBlue`, `DarkMagenta`, `DarkCyan`
**Background:** Maps to corresponding ANSI background codes (`BgBlack`, `BgRed`, etc.)
## Hyperlinks
OSC 8 hyperlinks for supported terminals (Windows Terminal, iTerm2, VS Code, etc.).
```csharp
// Write a clickable link
terminal.WriteLink("https://github.com", "GitHub");
terminal.WriteLinkLine("https://example.com", "Click here");
// String extension method
string link = "Click here".Link("https://example.com");
terminal.WriteLine(link);
// Styled hyperlink
terminal.WriteLine("Visit us".Link("https://example.com").Cyan().Underline());
// Check terminal support
if (terminal.SupportsHyperlinks)
terminal.WriteLinkLine("https://docs.com", "View docs");
else
terminal.WriteLine("View docs at https://docs.com");
```
## AnsiStringUtils
Utilities for working with ANSI-styled strings.
```csharp
// Get visible length (excludes ANSI codes)
int length = AnsiStringUtils.GetVisibleLength("Hello".Red()); // 5
// Strip all ANSI codes
string plain = AnsiStringUtils.StripAnsiCodes("\x1b[31mError\x1b[0m"); // "Error"
// Pad accounting for ANSI codes
string padded = AnsiStringUtils.PadRightVisible("Hi".Red(), 10);
string centered = AnsiStringUtils.CenterVisible("Title".Bold(), 40);
// Wrap text preserving ANSI codes
string[] lines = AnsiStringUtils.WrapText(longStyledText, maxWidth: 80);
```
---
---
title: TimeWarp.Builder
description: Fluent builder interfaces and scope extensions for TimeWarp projects
type: package
latest: 1.0.0
stable: 1.0.0
repository: https://github.com/TimeWarpEngineering/timewarp-builder
---
Fluent builder interfaces and scope extensions for TimeWarp projects
| | |
|---|---|
| Latest stable | `1.0.0` |
| Downloads | 3,976 |
| Last published | 2026-07-02 |
| Target frameworks | `net10.0` |
## Install
```sh
dotnet add package TimeWarp.Builder
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Builder) · [Source](https://github.com/TimeWarpEngineering/timewarp-builder)
---
# TimeWarp.Builder
[](https://www.nuget.org/packages/TimeWarp.Builder)
[](https://www.nuget.org/packages/TimeWarp.Builder)
[](https://github.com/TimeWarpEngineering/timewarp-builder/actions/workflows/workflow.yml)
[](LICENSE)
Fluent builder interfaces and Kotlin-inspired scope extensions for .NET.
## Installation
```bash
dotnet add package TimeWarp.Builder --prerelease
```
## Requirements
- .NET 10.0 or later
- Fully AOT- and trim-compatible (no reflection, no dynamic code)
## Interfaces
### IBuilder\
Interface for standalone builders that create objects via `Build()`. `TBuilt` is covariant, so an `IBuilder` can be used wherever an `IBuilder` is expected.
```csharp
public class MyWidgetBuilder : IBuilder
{
public Widget Build() => new Widget(_options);
}
// Usage
Widget widget = new MyWidgetBuilder()
.WithColor("blue")
.WithSize(10)
.Build();
```
### INestedBuilder\
Interface for nested builders that return to a parent context via `Done()`. `Done()` performs three things: builds the child, hands the result to the parent, and returns the parent for continued chaining.
```csharp
// Nested builder returns to parent after building
app.Map(route => route
.WithLiteral("deploy")
.WithParameter("env")
.Done()) // Returns to parent builder
.WithHandler(handler);
```
## Scope Extensions
Kotlin-inspired extension methods for fluent object manipulation. Because they attach to every type (unconstrained `T`), any object can participate in a fluent chain without its type opting in.
| Method | Returns | Use for |
|--------|---------|---------|
| `Also` | The original object | Side effects mid-chain (logging, diagnostics) |
| `Apply` | The original object | Configuring the object mid-chain |
| `Let` | The transform result | Converting to a different type/value |
| `Run` | Nothing (`void`) | Terminal action at the end of a chain |
### Also vs Apply
`Also` and `Apply` are mechanically identical — both execute an action and return the original object. They exist separately to signal *intent* at the call site, mirroring Kotlin's `also`/`apply` distinction: use `Apply` when the action configures the object itself, and `Also` when the action is an incidental side effect like logging.
```csharp
app.Map("status", handler)
.Apply(r => r.AsQuery()) // configures the route
.Also(r => logger.LogDebug("mapped {r}", r)); // side effect, not configuration
```
### Also
Executes an action on the object and returns the original object.
```csharp
var builder = new AppBuilder()
.Also(b => logger.LogDebug("Building app..."))
.Configure(options);
```
### Apply
Configures the object and returns the original object.
```csharp
app.Map("status", handler)
.Apply(r => r.AsQuery());
```
### Let
Transforms the object to a different type.
```csharp
int length = "hello".Let(s => s.Length); // 5
```
### Run
Executes an action on the object with no return value. Terminal operation in a method chain.
```csharp
app.Build().Run(a => a.RunAsync(args));
```
All four methods throw `ArgumentNullException` when the delegate is null.
## Used By
- [TimeWarp.Nuru](https://github.com/TimeWarpEngineering/timewarp-nuru) — route, endpoint, group, and key-binding builders implement `IBuilder` / `INestedBuilder`
- [TimeWarp.Terminal](https://github.com/TimeWarpEngineering/timewarp-terminal)
## Testing
Tests are [TimeWarp.Jaribu](https://github.com/TimeWarpEngineering/timewarp-jaribu) runfiles under `tests/`. Run them all with `dev test`, or any file directly:
```bash
dotnet run tests/scope-extensions.also.cs
```
## Unlicense
This is free and unencumbered software released into the public domain — see [LICENSE](LICENSE).
---
---
title: timewarp-heroicons
description: All of the Tailwind HeroIcons wrapped as Blazor components.
type: package
latest: 2.0.19+2.0.18
stable: 2.0.19+2.0.18
repository: https://github.com/TimeWarpEngineering/timewarp-heroicons
---
All of the Tailwind HeroIcons wrapped as Blazor components.
| | |
|---|---|
| Latest stable | `2.0.19+2.0.18` |
| Downloads | 3,523 |
| Last published | 2023-08-29 |
| Target frameworks | `net6.0` |
## Install
```sh
dotnet add package timewarp-heroicons
```
[NuGet](https://www.nuget.org/packages/timewarp-heroicons) · [Source](https://github.com/TimeWarpEngineering/timewarp-heroicons)
---
[](https://dotnet.microsoft.com)
[](https://github.com/TimeWarpEngineering/timewarp-heroicons)
[](https://discord.gg/7F4bS2T)
[](https://www.nuget.org/packages/timewarp-heroicons/)
[](https://www.nuget.org/packages/timewarp-heroicons/)
[](https://github.com/TimeWarpEngineering/timewarp-heroicons/issues)
[](https://github.com/TimeWarpEngineering/timewarp-heroicons)
[](https://unlicense.org)
[](https://twitter.com/intent/tweet?url=https://github.com/TimeWarpEngineering/timewarp-heroicons)
[](https://twitter.com/intent/follow?screen_name=StevenTCramer)
[](https://twitter.com/intent/follow?screen_name=TheFreezeTeam1)
# timewarp-heroicons
All the HeroIcons wrapped as Blazor components.

All [heroicons](https://github.com/tailwindlabs/heroicons) wrapped as Blazor components.
See and search all at https://heroicons.com/
## Give a Star! :star:
If you like or are using this project please give it a star. Thank you!
## Usage
```razor
```
Outputs

## Installation
You can see the latest NuGet packages from the official [TimeWarp NuGet page](https://www.nuget.org/profiles/TimeWarp.Enterprises).
* [timewarp-heroicons](https://www.nuget.org/packages/timewarp-heroicons/) [](https://www.nuget.org/packages/timewarp-heroicons/)
```console
dotnet add package timewarp-heroicons
```
## License
[](https://unlicense.org)
## Contributing
Time is of the essence. Before developing a Pull Request I recommend opening a [discussion](https://github.com/TimeWarpEngineering/timewarp-heroicons/discussions).
Please feel free to make suggestions and help out with the [documentation](https://timewarpengineering.github.io/timewarp-heroicons/).
Please refer to [Markdown](http://daringfireball.net/projects/markdown/) for how to write markdown files.
### Steps to publish NuGet package
* [ ] Clone the [heroicons](https://github.com/tailwindlabs/heroicons) repo.
* [ ] Set the PowerShell variable `$heroicons` to the path where you cloned the heroicons repo in the above step. (Add `$heroicons = ""` to your profile)
* [ ] Ensure your copy of the heroicons repo is up to date by running (`update.ps1`).
* [ ] Set the Version in `timewarp-heroicons/source/timewarp-heroicons/timewarp-heroicons.csproj` to the same version that is in `simple-icons/package.json`.
* [ ] Transform the cloned [simple-icons](https://github.com/simple-icons/simple-icons) into razor files by running `transform.ps1`.
* [ ] Run the test app to make sure the icons render properly.
* [ ] Update `releases.md`.
* [ ] Commit and push the changes to GitHub.
* [ ] Tweet to let people know.
## Contact
Sometimes the github notifications get lost in the shuffle. If you file an [issue](https://github.com/TimeWarpEngineering/timewarp-heroicons/issues) and don't get a response in a timely manner feel free to ping on our [Discord server](https://discord.gg/A55JARGKKP).
[](https://discord.gg/7F4bS2T)
## References
https://github.com/heroicons/heroicons
### Commands used
```PowerShell
dotnet new sln
dotnet new razorclasslib -n timewarp-heroicons
dotnet sln add .\Source\timewarp-heroicons\timewarp-heroicons.csproj
dotnet new tool-manifest
dotnet tool install dotnet-cleanup
dotnet cleanup -y
```
---
---
title: TimeWarp.Cli
description: Fluent API for elegant C# scripting with pipeline support
type: package
latest: 0.6.0-rc9
stable: none
repository: https://github.com/TimeWarpEngineering/timewarp-amuru
---
Fluent API for elegant C# scripting with pipeline support
| | |
|---|---|
| Latest prerelease | `0.6.0-rc9` |
| Stable release | none yet (prerelease only) |
| Downloads | 3,384 |
| Last published | 2025-07-17 |
| Target frameworks | `net10.0` |
## Install
```sh
dotnet add package TimeWarp.Cli --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Cli) · [Source](https://github.com/TimeWarpEngineering/timewarp-amuru) · Part of the [timewarp-amuru](/projects/timewarp-amuru/) family
See [TimeWarp.Amuru](/packages/timewarp.amuru/) for the full documentation of this family.
---
---
title: TimeWarp.Jaribu
description: Lightweight testing helpers for single-file C# programs and scripts. Jaribu (Swahili: test/trial) provides TestRunner pattern and assertion helpers for executable .cs files.
type: package
latest: 1.0.0-beta.13
stable: none
repository: https://github.com/TimeWarpEngineering/timewarp-jaribu
---
Lightweight testing helpers for single-file C# programs and scripts. Jaribu (Swahili: test/trial) provides TestRunner pattern and assertion helpers for executable .cs files.
| | |
|---|---|
| Latest prerelease | `1.0.0-beta.13` |
| Stable release | none yet (prerelease only) |
| Downloads | 2,660 |
| Last published | 2026-06-02 |
| Target frameworks | `net10.0` |
## Install
```sh
dotnet add package TimeWarp.Jaribu --prerelease
```
[NuGet](https://www.nuget.org/packages/TimeWarp.Jaribu) · [Source](https://github.com/TimeWarpEngineering/timewarp-jaribu) · Part of the [timewarp-jaribu](/projects/timewarp-jaribu/) family
---
# TimeWarp.Jaribu
Lightweight test framework for .NET with two execution modes:
- **Runfile Mode**: Direct `.cs` file execution for rapid development
- **M.T.P. Mode**: IDE integration and `dotnet test` support
Jaribu (Swahili: test/trial) provides a convention-based TestRunner pattern that discovers public static async Task methods as tests. Write once, run anywhere—from quick scripts to full IDE integration.
## Features
- **Convention over Configuration**: Discover public static async Task methods as tests via reflection.
- **Assertion Helpers**: Simple, fluent assertions inspired by Shouldly.
- **Attributes**: Support for [Skip], [TestTag], [Timeout], and [Input].
- **Parameterized Tests**: Easy data-driven testing.
- **Tag Filtering**: Run specific test groups.
- **Minimal Dependencies**: Only Shouldly for assertions.
- **Visual Studio Test Explorer integration** (M.T.P. Mode)
- **VS Code Test Explorer integration** (M.T.P. Mode)
- **`dotnet test` support** (M.T.P. Mode)
## Two Execution Modes
TimeWarp.Jaribu supports two distinct ways to run your tests:
| Mode | Best For | How to Run |
|------|----------|------------|
| **Runfile Mode** | Rapid development, single-file tests | `./my-tests.cs` (Linux/macOS) or `dotnet my-tests.cs` |
| **M.T.P. Mode** | IDE integration, team CI | `dotnet test` |
Both modes use the same test discovery conventions and attributes. Your test classes work in either mode without modification.
### When to Use Runfile Mode
- Rapid prototyping and experimentation
- Single-file test apps that run like shell scripts (Linux/macOS shebang support)
- CI pipelines with custom orchestration
- When you prefer direct execution without project files
- Unix-style workflows where tests are executable scripts
### When to Use M.T.P. Mode
- Visual Studio or VS Code Test Explorer integration
- Standard `dotnet test` workflow
- Team environments with mixed IDEs
- CI pipelines expecting standard test output (TRX, JUnit, etc.)
## Installation
For **Runfile Mode** (single-file scripts):
```
dotnet add package TimeWarp.Jaribu
```
For **M.T.P. Mode** (IDE integration and `dotnet test`):
```
dotnet add package TimeWarp.Jaribu.TestingPlatform
```
---
## Runfile Mode
Runfile Mode executes test files directly without a project file. Ideal for rapid development and single-file tests.
On **Linux/macOS**, test files with a shebang can be executed directly like scripts:
```bash
./my-tests.cs # Direct execution (requires shebang + chmod +x)
dotnet my-tests.cs # Works on all platforms
```
### Basic Test File (Runfile)
Create a single-file test script (e.g., `my-tests.cs`):
```csharp
#!/usr/bin/env dotnet run
#:package TimeWarp.Jaribu
using static TimeWarp.Jaribu.TestHelpers;
return await RunAllTests();
public static class MyTests
{
[System.Runtime.CompilerServices.ModuleInitializer]
internal static void Register() => RegisterTests();
public static async Task BasicTest()
{
1.ShouldBe(1);
}
[TestTag("integration")]
public static async Task IntegrationTest()
{
// Test logic here
}
}
```
Make it executable and run directly (Linux/macOS):
```bash
chmod +x my-tests.cs
./my-tests.cs
```
Or run with dotnet (all platforms):
```bash
dotnet my-tests.cs
```
### TestRunner
For programmatic use:
```csharp
using TimeWarp.Jaribu;
// Simple usage - returns exit code (0 = success, 1 = failure)
int exitCode = await TestRunner.RunTests();
// Sink-based API - get detailed test information via ITestResultSink
// Use NullSink for silent execution, TerminalSink for console output
using TerminalSink sink = new();
TestRunStats stats = await TestRunner.RunTestsAsync(sink);
// Access aggregated stats
Console.WriteLine($"Passed: {stats.PassedCount}");
Console.WriteLine($"Failed: {stats.FailedCount}");
Console.WriteLine($"Skipped: {stats.SkippedCount}");
Console.WriteLine($"Duration: {stats.Duration}");
Console.WriteLine($"Success: {stats.Success}");
```
### Multi-Class Test Registration
Run tests from multiple test classes with aggregated results:
```csharp
using TimeWarp.Jaribu;
// Register test classes explicitly (no assembly scanning)
TestRunner.RegisterTests();
TestRunner.RegisterTests();
TestRunner.RegisterTests();
// Run all registered and get exit code (0 = success, 1 = failure)
return await TestRunner.RunAllTests();
// Or with tag filter
return await TestRunner.RunAllTests(filterTag: "Unit");
```
**Note**: Use `TestRunner.ClearRegisteredTests()` to clear all registrations if needed.
### Multi-File Test Orchestration
Organize tests across multiple files that work both standalone and aggregated:
- **Standalone mode**: Run individual test files directly with `dotnet file.cs`
- **Multi mode**: An orchestrator compiles multiple test files together with aggregated results
This pattern uses `[ModuleInitializer]` for auto-registration and conditional compilation to prevent double-execution.
#### Test file pattern
```csharp
#!/usr/bin/dotnet --
#:project ../../source/MyProject/MyProject.csproj
#if !JARIBU_MULTI
return await RunAllTests();
#endif
[TestTag("Unit")]
public class MyTests
{
[ModuleInitializer]
internal static void Register() => RegisterTests();
public static async Task SomeTest()
{
// Test logic
}
}
```
**Key elements:**
- `#!/usr/bin/dotnet --` enables direct execution as a script
- `#:project` references dependencies (Jaribu, your project, etc.)
- `#if !JARIBU_MULTI` only self-executes when run standalone
- `[ModuleInitializer]` auto-registers when compiled in multi mode
#### Create an orchestrator
Create a simple entry point that runs all auto-registered tests:
```csharp
#!/usr/bin/dotnet --
#:project ../source/MyProject/MyProject.csproj
// Tests auto-registered via [ModuleInitializer]
return await RunAllTests();
```
#### Configure Directory.Build.props
Configure which test files to include and define the `JARIBU_MULTI` constant:
```xml
$(DefineConstants);JARIBU_MULTI
```
This allows CI pipelines to run different subsets of tests by configuring separate orchestrators with different file includes.
#### Real-world example
Jaribu uses this pattern for its own test suite:
- `tests/TimeWarp.Jaribu.Tests/jaribu-*.cs` - Test files following the dual-mode pattern
- `tests/TimeWarp.Jaribu.Tests/ci-tests/` - CI orchestrator with curated test selection
---
## M.T.P. Mode
M.T.P. (Microsoft.Testing.Platform) Mode integrates with Visual Studio Test Explorer, VS Code Test Explorer, and the standard `dotnet test` command.
### Project Setup
Create a test project with the TestingPlatform package:
```xml
net10.0Exeenableenable
```
### Test Class Example
```csharp
using System.Runtime.CompilerServices;
using static TimeWarp.Jaribu.TestHelpers;
public class MyTests
{
[ModuleInitializer]
internal static void Register() => RegisterTests();
public static async Task AdditionTest()
{
(1 + 1).ShouldBe(2);
await Task.CompletedTask;
}
[TestTag("Integration")]
public static async Task IntegrationTest()
{
// Integration test logic
await Task.CompletedTask;
}
[Skip("Not yet implemented")]
public static async Task FutureTest()
{
await Task.CompletedTask;
}
}
```
### Running Tests
```bash
# Run all tests
dotnet test
# Run with detailed output
dotnet test --logger "console;verbosity=detailed"
# List discovered tests
dotnet run -- --list-tests
# Filter by test name
dotnet run -- --filter "Name~Addition"
# Run directly (also works)
dotnet run
```
### IDE Integration
1. Open the test project in Visual Studio or VS Code
2. Test Explorer automatically discovers all registered test classes
3. Run, debug, or filter tests from the Test Explorer panel
**Visual Studio**: Tests appear in Test Explorer (Test → Test Explorer)
**VS Code**: Install the C# Dev Kit extension; tests appear in the Testing sidebar
---
## API Reference
### Core Types
```csharp
// Test state aligned with Microsoft.Testing.Platform
public enum TestNodeState
{
Discovered, InProgress, Passed, Failed,
Skipped, Timeout, Error, Cancelled
}
// Individual test result
public record TestNodeInfo(
string Uid, // "Namespace.Class.Method"
string DisplayName, // "MethodName" or "MethodName(param1, param2)"
TestNodeState State,
TimeSpan? Duration = null,
Exception? Exception = null,
string? Message = null,
IReadOnlyList