8 breaking releases

0.9.0 Dec 5, 2023
0.8.0 Sep 15, 2023
0.7.0 May 17, 2023
0.6.0 Feb 10, 2023
0.4.0 Nov 19, 2022

#1279 in Network programming

Download history 24/week @ 2023-10-07 36/week @ 2023-10-14 31/week @ 2023-10-21 39/week @ 2023-10-28 31/week @ 2023-11-04 42/week @ 2023-11-11 33/week @ 2023-11-18 54/week @ 2023-11-25 115/week @ 2023-12-02 206/week @ 2023-12-09 79/week @ 2023-12-16 70/week @ 2023-12-23 32/week @ 2023-12-30 33/week @ 2024-01-06 29/week @ 2024-01-13 22/week @ 2024-01-20

129 downloads per month
Used in 3 crates (2 directly)

MIT license

115KB
3K SLoC

Azalea Brigadier

A Rust port of Mojang's Brigadier command parsing and dispatching library.

Examples

use azalea_brigadier::prelude::*;
use std::sync::Arc;

#[derive(Debug, PartialEq)]
struct CommandSource {}

let mut subject = CommandDispatcher::new();
subject.register(literal("foo").executes(|_| 42));

assert_eq!(
    subject
        .execute("foo", Arc::new(CommandSource {}))
        .unwrap(),
    42
);

See the tests for more.

Dependencies

~0.4–6.5MB
~19K SLoC