osc-devtools

Crates.ioosc-devtools
lib.rsosc-devtools
version0.1.0-alpha.3
created_at2025-10-27 03:19:36.555623+00
updated_at2025-10-27 04:33:23.299639+00
descriptionExperimental CLI tools and examples for osc-data-model workspace
homepagehttps://github.com/Nagitch/osc-data-model
repositoryhttps://github.com/Nagitch/osc-data-model
max_upload_size
id1902184
size20,081
Nagitch (Nagitch)

documentation

https://docs.rs/osc-devtools

README

osc-devtools

⚠️ EXPERIMENTAL ⚠️
This crate is experimental and APIs may change significantly between versions.

CLI tools and examples for the osc-data-model workspace, providing utilities for testing, debugging, and demonstrating OSC intermediate representation functionality.

Installation

cargo install osc-devtools --version 0.1.0-alpha.1

Or build from source:

git clone https://github.com/Nagitch/osc-data-model
cd osc-data-model
cargo build --release --bin osc-devtools

Usage

The CLI provides subcommands for testing and demonstrating OSC data conversion:

# Show help
osc-devtools --help

# Test JSON roundtrip conversion
osc-devtools json-roundtrip

# Test MessagePack roundtrip conversion
osc-devtools msgpack-roundtrip

# Demonstrate complex bundle nesting and conversion
osc-devtools bundle-demo

Examples

JSON Roundtrip Testing

Test that data survives JSON serialization and deserialization:

# Test JSON roundtrip with simple string data
osc-devtools json-roundtrip

MessagePack Roundtrip Testing

Test that data survives MessagePack serialization and deserialization:

# Test MessagePack roundtrip with simple string data
osc-devtools msgpack-roundtrip

Bundle Demo

Demonstrate complex nested bundle structures and cross-format conversion:

# Creates complex nested bundles and tests conversion
osc-devtools bundle-demo

This command:

  • Creates complex nested bundle structures
  • Tests JSON and MessagePack roundtrip conversion
  • Verifies cross-codec compatibility
  • Reports conversion success and data sizes

Development Usage

The tools are useful for:

  • Testing codec implementations with real data
  • Debugging serialization issues across formats
  • Performance benchmarking of different formats
  • Generating test fixtures for other projects
  • Validating OSC data structures before processing

Command Reference

json-roundtrip

Tests JSON serialization and deserialization using a simple string value.

msgpack-roundtrip

Tests MessagePack serialization and deserialization using a simple string value.

bundle-demo

Demonstrates complex nested bundle creation and tests both JSON and MessagePack conversion with cross-format compatibility verification.

Dependencies

  • osc-ir: Core IR types
  • osc-codec-json: JSON serialization
  • osc-codec-msgpack: MessagePack serialization
  • clap: Command-line argument parsing
  • anyhow: Error handling

License

Licensed under either of

at your option.

Commit count: 0

cargo fmt