[package]
name = "looop"
version = "0.22.0"
edition = "2024"
description = "A tiny, portable, Kubernetes-shaped control loop for your work"
license = "MIT"
repository = "https://github.com/yusukeshib/looop"
readme = "README.md"

[[bin]]
name = "looop"
path = "src/main.rs"

[dependencies]
clap = { version = "4", features = ["derive"] }
serde = { version = "1", features = ["derive"] }
serde_json = "1"
anyhow = "1"
chrono = { version = "0.4", default-features = false, features = ["clock", "std"] }
# babysit as a library: drive the worker fleet in-process instead of shelling
# out to the `babysit` binary + re-parsing JSON (step 3 of the port).
# default-features = false drops the `upgrade` feature (self_update), keeping
# the network stack out of looop.
babysit = { version = "0.12", default-features = false }
# looop drives babysit's async API in-process, including the detached worker
# supervisor (serve_worker), which babysit runs under a multi-thread runtime
# (`#[tokio::main]`). Match that so the in-process worker behaves identically.
tokio = { version = "1", features = ["rt", "rt-multi-thread", "net", "time", "io-util", "signal"] }
# `looop watch`: a two-pane TUI (live colored log + running-session selector).
# ratatui re-exports its crossterm backend, so we drive terminal setup/events
# through `ratatui::crossterm` and don't pin crossterm separately. ansi-to-tui
# parses the PTY log's ANSI/SGR escapes into styled ratatui lines so the log
# pane stays colored.
ratatui = "0.30"
ansi-to-tui = "8"
# `looop watch` replays the raw PTY `output.log` through a virtual terminal so
# an interactive agent's in-place redraws (cursor moves, line clears) render as
# the actual SCREEN instead of a garbled append of every frame. babysit already
# depends on vt100 (and exposes `render::render_screen`); we pin it directly to
# name the `vt100::Parser`/`Screen` types and drive scrollback ourselves.
vt100 = "0.16"

[profile.release]
strip = true
lto = true
