mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-08-28 05:27:41 +00:00
Remove deprecated fabro init command
Users should use `fabro repo init` instead. The deprecation shim has been in place long enough; remove it and update all docs references. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
93aa239056
commit
d50b3187e5
9 changed files with 45 additions and 73 deletions
12
AGENTS.md
12
AGENTS.md
|
|
@ -50,7 +50,7 @@ The OpenAPI spec at `docs/api-reference/fabro-api.yaml` is the source of truth f
|
|||
Fabro is an AI-powered workflow orchestration platform. Workflows are defined as Graphviz graphs, where each node is a stage (agent, prompt, command, conditional, human, parallel, etc.) executed by the workflow engine.
|
||||
|
||||
### Rust crates (`lib/crates/`)
|
||||
- **fabro-cli** — CLI entry point. Commands: `run`, `exec`, `serve`, `validate`, `parse`, `cp`, `model`, `doctor`, `init`, `install`, `ps`, `system prune`, `llm`
|
||||
- **fabro-cli** — CLI entry point. Commands: `run`, `exec`, `serve`, `validate`, `parse`, `cp`, `model`, `doctor`, `install`, `ps`, `system prune`, `llm`
|
||||
- **fabro-workflow** — Core workflow engine. Parses Graphviz graphs, runs stages, manages checkpoints/resume, hooks, retros, and human-in-the-loop interactions
|
||||
- **fabro-agent** — AI coding agent with tool use (Bash, Read, Write, Edit, Glob, Grep, WebFetch). `Sandbox` trait abstracts execution environments
|
||||
- **fabro-server** — Axum HTTP server. Routes for runs, sessions, models, completions, usage. SSE event streaming. Demo mode via header
|
||||
|
|
@ -92,6 +92,16 @@ When interpolating values into shell command strings (in `fabro-workflow`), alwa
|
|||
- **Functions**: import the parent module, call as `module::function()` — `use fabro_workflow::operations; operations::create(...)`
|
||||
- **No glob imports** in production code (`use foo::*`). Globs are acceptable in test modules and preludes. Enforced by clippy `wildcard_imports` lint.
|
||||
|
||||
## Snapshot tests (insta)
|
||||
|
||||
Many CLI tests use `insta` inline snapshots. When a snapshot needs updating:
|
||||
|
||||
1. Run `cargo insta pending-snapshots` to list what changed
|
||||
2. Verify each pending snapshot is expected
|
||||
3. Run `cargo insta accept` to accept all, or `cargo insta accept --snapshot <path>` for a specific one
|
||||
|
||||
Never run `cargo insta accept` without first checking what's pending — it accepts *all* pending snapshots, which may include unrelated changes.
|
||||
|
||||
## Testing workflows
|
||||
|
||||
- `fabro run <name>` — run a workflow by name (resolves `fabro/workflows/<name>/workflow.toml`), e.g. `fabro run repl`
|
||||
|
|
|
|||
|
|
@ -124,7 +124,7 @@ Then initialize Fabro in your project:
|
|||
fabro install # one-time setup
|
||||
|
||||
cd my-project
|
||||
fabro init # per project
|
||||
fabro repo init # per project
|
||||
```
|
||||
|
||||
---
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ Fabro has two modes:
|
|||
|
||||
```bash
|
||||
cd my-repo/
|
||||
fabro init
|
||||
fabro repo init
|
||||
```
|
||||
|
||||
This creates a default workflow and configuration in your project directory.
|
||||
|
|
|
|||
|
|
@ -648,10 +648,6 @@ The command must be run inside a git repository. It creates:
|
|||
|
||||
After creating files, it checks whether the GitHub App is installed for the repository. If the app is not installed and the repository owner differs from the app owner, it warns that the app may need to be [made public](/integrations/github#github-app-is-private-but-this-repo-belongs-to-a-different-owner) first.
|
||||
|
||||
<Note>
|
||||
The old `fabro init` still works but prints a deprecation warning. Use `fabro repo init` instead.
|
||||
</Note>
|
||||
|
||||
## `fabro repo deinit`
|
||||
|
||||
Remove Fabro from a project by deleting `fabro.toml` and the `fabro/` directory. Fails with an error if the project is not initialized.
|
||||
|
|
|
|||
|
|
@ -777,9 +777,6 @@ pub(crate) enum Commands {
|
|||
#[arg(long)]
|
||||
dry_run: bool,
|
||||
},
|
||||
/// Initialize a new project (deprecated: use `repo init`)
|
||||
#[command(hide = true)]
|
||||
Init,
|
||||
/// Set up the Fabro environment (LLMs, certs, GitHub)
|
||||
Install {
|
||||
/// Base URL for the web UI (used for OAuth callback URLs)
|
||||
|
|
@ -865,7 +862,6 @@ impl Commands {
|
|||
RepoCommand::Init { .. } => "repo init",
|
||||
RepoCommand::Deinit => "repo deinit",
|
||||
},
|
||||
Self::Init => "init",
|
||||
Self::Install { .. } => "install",
|
||||
Self::Pr(ns) => match &ns.command {
|
||||
PrCommand::Create(_) => "pr create",
|
||||
|
|
|
|||
|
|
@ -158,7 +158,6 @@ async fn main_inner() -> (String, Result<()>) {
|
|||
Commands::RunCmd(RunCommands::Run(_) | RunCommands::Create(_))
|
||||
| Commands::Exec(_)
|
||||
| Commands::Repo(_)
|
||||
| Commands::Init
|
||||
| Commands::Install { .. }
|
||||
) {
|
||||
commands::upgrade::spawn_upgrade_check(globals.no_upgrade_check, upgrade_check_enabled)
|
||||
|
|
@ -207,10 +206,6 @@ async fn main_inner() -> (String, Result<()>) {
|
|||
open::that("https://docs.fabro.sh/")?;
|
||||
}
|
||||
Commands::Repo(ns) => commands::repo::dispatch(ns).await?,
|
||||
Commands::Init => {
|
||||
fabro_util::warn_user!("`fabro init` is deprecated, use `fabro repo init` instead");
|
||||
commands::repo::init::run_init().await?;
|
||||
}
|
||||
Commands::Install { web_url } => {
|
||||
commands::install::run_install(&web_url).await?;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,37 +12,38 @@ fn help() {
|
|||
Usage: fabro [OPTIONS] <COMMAND>
|
||||
|
||||
Commands:
|
||||
run Launch a workflow run
|
||||
create Create a workflow run (allocate run dir, persist spec)
|
||||
start Start a created workflow run (spawn engine process)
|
||||
attach Attach to a running or finished workflow run
|
||||
logs View the event log of a workflow run
|
||||
resume Resume an interrupted workflow run
|
||||
rewind Rewind a workflow run to an earlier checkpoint
|
||||
fork Fork a workflow run from an earlier checkpoint into a new run
|
||||
wait Block until a workflow run completes
|
||||
preflight Validate run configuration without executing
|
||||
validate Validate a workflow
|
||||
graph Render a workflow graph as SVG or PNG
|
||||
asset Inspect and copy run assets (screenshots, reports, traces)
|
||||
store Export store-backed run state for debugging
|
||||
rm Remove one or more workflow runs
|
||||
inspect Show detailed information about a workflow run
|
||||
model List and test LLM models
|
||||
doctor Check environment and integration health
|
||||
install Set up the Fabro environment (LLMs, certs, GitHub)
|
||||
pr Pull request operations
|
||||
secret Manage secrets in ~/.fabro/.env
|
||||
settings Inspect merged configuration
|
||||
workflow Workflow operations
|
||||
discord Open the Discord community in the browser
|
||||
docs Open the docs website in the browser
|
||||
upgrade Upgrade fabro to the latest version
|
||||
repo Repository commands
|
||||
provider Provider operations
|
||||
sandbox Sandbox operations (cp, ssh, preview)
|
||||
system System maintenance commands
|
||||
help Print this message or the help of the given subcommand(s)
|
||||
run Launch a workflow run
|
||||
create Create a workflow run (allocate run dir, persist spec)
|
||||
start Start a created workflow run (spawn engine process)
|
||||
attach Attach to a running or finished workflow run
|
||||
logs View the event log of a workflow run
|
||||
resume Resume an interrupted workflow run
|
||||
rewind Rewind a workflow run to an earlier checkpoint
|
||||
fork Fork a workflow run from an earlier checkpoint into a new run
|
||||
wait Block until a workflow run completes
|
||||
preflight Validate run configuration without executing
|
||||
validate Validate a workflow
|
||||
graph Render a workflow graph as SVG or PNG
|
||||
asset Inspect and copy run assets (screenshots, reports, traces)
|
||||
store Export store-backed run state for debugging
|
||||
rm Remove one or more workflow runs
|
||||
inspect Show detailed information about a workflow run
|
||||
model List and test LLM models
|
||||
doctor Check environment and integration health
|
||||
install Set up the Fabro environment (LLMs, certs, GitHub)
|
||||
pr Pull request operations
|
||||
secret Manage secrets in ~/.fabro/.env
|
||||
settings Inspect merged configuration
|
||||
workflow Workflow operations
|
||||
discord Open the Discord community in the browser
|
||||
docs Open the docs website in the browser
|
||||
upgrade Upgrade fabro to the latest version
|
||||
repo Repository commands
|
||||
provider Provider operations
|
||||
sandbox Sandbox operations (cp, ssh, preview)
|
||||
completion Generate shell completions
|
||||
system System maintenance commands
|
||||
help Print this message or the help of the given subcommand(s)
|
||||
|
||||
Options:
|
||||
--debug Enable DEBUG-level logging (default is INFO) [env: FABRO_DEBUG=]
|
||||
|
|
|
|||
|
|
@ -1,25 +0,0 @@
|
|||
use fabro_test::{fabro_snapshot, test_context};
|
||||
|
||||
#[test]
|
||||
fn help() {
|
||||
let context = test_context!();
|
||||
let mut cmd = context.init_cmd();
|
||||
cmd.arg("--help");
|
||||
fabro_snapshot!(context.filters(), cmd, @"
|
||||
success: true
|
||||
exit_code: 0
|
||||
----- stdout -----
|
||||
Initialize a new project (deprecated: use `repo init`)
|
||||
|
||||
Usage: fabro init [OPTIONS]
|
||||
|
||||
Options:
|
||||
--debug Enable DEBUG-level logging (default is INFO) [env: FABRO_DEBUG=]
|
||||
--no-upgrade-check Disable automatic upgrade check [env: FABRO_NO_UPGRADE_CHECK=true]
|
||||
--quiet Suppress non-essential output [env: FABRO_QUIET=]
|
||||
--verbose Enable verbose output [env: FABRO_VERBOSE=]
|
||||
--storage-dir <STORAGE_DIR> Storage directory (default: ~/.fabro) [env: FABRO_STORAGE_DIR=[STORAGE_DIR]]
|
||||
-h, --help Print help
|
||||
----- stderr -----
|
||||
");
|
||||
}
|
||||
|
|
@ -16,7 +16,6 @@ mod exec;
|
|||
mod fabro;
|
||||
mod fork;
|
||||
mod graph;
|
||||
mod init;
|
||||
mod inspect;
|
||||
mod install;
|
||||
mod llm;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue