| Crates.io | oxur-cli |
| lib.rs | oxur-cli |
| version | 0.2.0 |
| created_at | 2026-01-03 17:50:57.049915+00 |
| updated_at | 2026-01-17 00:33:05.151833+00 |
| description | CLI infrastructure and unified command-line tool for Oxur |
| homepage | |
| repository | https://github.com/oxur/oxur |
| max_upload_size | |
| id | 2020521 |
| size | 395,099 |
Unified CLI infrastructure for Oxur.
This crate provides two things:
Library: Common utilities for building Oxur CLI tools
Binary: The unified oxur command-line tool
All Oxur CLI tools use this library for consistency.
[dependencies]
oxur-cli = { path = "../oxur-cli" }
use oxur_cli::common::io::{read_input, write_output};
use std::path::PathBuf;
// Read from file or stdin (-)
let content = read_input(&PathBuf::from("input.txt"))?;
// Process...
// Write to file or stdout (-)
write_output(&result, Some(&PathBuf::from("output.txt")))?;
use oxur_cli::common::output::{success, error, info, warning};
info("Processing files...");
// ... work ...
success("All files processed!");
// Or with errors:
error("Failed to process file");
warning("Skipping invalid entry");
use oxur_cli::common::progress::ProgressTracker;
let mut progress = ProgressTracker::new(verbose);
progress.step("Loading data");
// ... work ...
progress.done();
progress.step("Processing data");
// ... work ...
progress.done();
progress.success("All done!");
The oxur binary provides unified access to Oxur functionality.
oxur compile input.ox -o output
Compile an Oxur file to a native binary.
oxur run input.ox -- arg1 arg2
Compile and run an Oxur file with arguments.
oxur repl
Start the interactive REPL.
oxur new my-project
Create a new Oxur project with standard structure.
oxur build
oxur build --release
Build the current project.
oxur test
Run tests in the current project.
cargo build --lib
cargo build --bin oxur --features binary
cargo test
oxur-cli
├── Library (common utilities)
│ ├── io - File I/O helpers
│ ├── output - Colored terminal output
│ └── progress - Progress tracking
│
└── Binary (unified CLI)
└── main - Entry point for `oxur` command
MIT OR Apache-2.0