Chronis - Event-Sourced Task CLI for Rust
Description: Chronis is an event-sourced task CLI powered by the AllSource embedded database (all-source.xyz). Every action is an immutable event. State is derived from projections over the event stream.
Keywords: rust, cli, task management, event sourcing, cqrs, wal, parquet, tui, developer tools

# Event-Sourced Task CLI

Every action is an immutable event. State is derived from projections over the event stream. Powered by AllSource, the embedded event database.

Rust 2024 Edition Event Sourced ~12us Reads
`# Install from crates.io
$ cargo install chronis
# Initialize workspace
$ cn init
# Create your first task
$ cn task create "Design auth module" -p p0`
View on GitHub Read the Docs

## Why Chronis?

### Immutable Event Log Event Sourcing

Every mutation emits an event into Core's WAL. Full audit trail, time-travel debugging, and reproducible state from any point in history.

### Microsecond Reads Core

TaskProjection folds events into a DashMap for ~12us concurrent reads. 469K events/sec write throughput with CRC32 integrity checks.

### Full Durability Core

WAL with configurable fsync (default 100ms) and Parquet columnar storage with Snappy compression. Data survives crashes and restarts.

### Task Hierarchy Core

Epics contain child tasks. Dependencies with blocking semantics. The `cn ready` command shows only unblocked, actionable work.

### Agent Orchestration Event Sourcing

Set `CN_AGENT_ID` to coordinate multiple agents. First-write-wins claiming prevents conflicts. Every claim is an auditable event.

### Interactive TUI UI

Full ratatui terminal interface with j/k navigation, Tab views, and c/d/a action keys. Or launch the embedded Axum + HTMX web viewer.

### Git Sync Core

One command to stage, commit, and push your `.chronis/` workspace. Tasks travel with your repository.

### Beads Migration Event Sourcing

Import existing issues from `.beads/` directories. Preserves history as creation events in the new event stream.

### Zero Config Core

`cn init` creates a `.chronis/` workspace. No external database, no daemon, no configuration file to edit. Just works.

## Workflow

From backlog to shipped in four commands

cn ready
Find actionable work
→
cn claim <id>
Claim the task
→
(do work)
Write code
→
cn done <id>
Mark complete
→
cn sync --git
Push to remote

## Commands

Command | Alias | Description
--- | --- | ---
`cn init` |  | Initialize a `.chronis/` workspace
`cn task create <title>` |  | Create a task with optional flags
`cn list` | `cn ls` | List tasks, optionally filtered by status
`cn ready` | `cn r` | Show open, unblocked tasks
`cn show <id>` | `cn s` | Task details, children, and event timeline
`cn claim <id>` | `cn c` | Claim a task (first-write-wins)
`cn done <id>` | `cn d` | Mark a task as done
`cn approve <id>` |  | Approve a completed task
`cn dep add <id> <blocker>` |  | Add a blocking dependency
`cn dep remove <id> <blocker>` |  | Remove a blocking dependency
`cn tui` |  | Interactive terminal UI
`cn serve` |  | Embedded web viewer (Axum + HTMX)
`cn sync --git` |  | Stage, commit, and push .chronis/
`cn migrate-beads` |  | Import issues from .beads/ directory

## Task Creation Flags

Fine-grained control over every task

`$ cn task create "Title" \
-p p1 \ # p0 (critical), p1, p2 (default), p3
--type=epic \ # task, epic, bug, feature
--parent=<id> \ # Parent task for hierarchy
--blocked-by=<id> \ # Dependency
-d "Description" # Optional description`

## Architecture

cn CLI (clap)
|
v
TaskRepository trait
|
v
EmbeddedCore (allsource-core)
|
+--> WAL (CRC32, fsync) --> Parquet (Snappy)
+--> DashMap (in-memory reads, ~12us)
+--> TaskProjection (event folding)

## Event Types

All state is derived from these immutable events

`task.created` cn task create
`task.updated` cn task update
`task.dependency.added` cn dep add
`task.dependency.removed` cn dep remove
`workflow.claimed` cn claim
`workflow.step.completed` cn done
`workflow.approval.granted` cn approve
~12us
Query Latency
469K
Events/sec Write
11
Integration Tests
0
External Dependencies

## Get Started

Created by Decebal Dobrica. Part of the AllSource ecosystem. Install from crates.io and start managing tasks with immutable events.

crates.io GitHub