STREAM_NAME := "EMERGENCY_AUDIO_STREAMS"

install-toolchain:
    rustup install

update:
    cargo update

check:
    cargo check

dev:
    ENVIRONMENT=development cargo run

test:
    cargo test --all-features

lint-rust-clippy:
    cargo clippy

lint-rust-clippy-fix:
    cargo clippy --fix --allow-dirty --allow-staged

lint-rust-rustfmt:
    cargo fmt --all -- --check

lint-rust-rustfmt-fix:
    cargo fmt --all

stream-create:
    nats stream add --config="src/{{ STREAM_NAME }}.json"

stream-delete:
    nats stream delete "{{ STREAM_NAME }}" --force

stream-info:
    nats stream info "{{ STREAM_NAME }}"

stream-subscribe:
    nats subscribe --stream="{{ STREAM_NAME }}"
