ad_event

Crates.ioad_event
lib.rsad_event
version0.3.0
created_at2024-10-02 07:04:51.384054+00
updated_at2025-02-19 19:57:37.359931+00
descriptionA shared event format for ad and its clients
homepage
repositoryhttps://github.com/sminez/ad/crates/ad_event
max_upload_size
id1393775
size10,161
Innes Anderson-Morrison (sminez)

documentation

https://docs.rs/ad-editor

README

ad_event :: a shared event format for ad and client programs

Example Format

M L 160 173 14 | screenshot.png
{"source":"M","kind":"L","ch_from":169,"ch_to":173,"truncated":false,"txt":"screenshot.png"}
#!/usr/bin/env sh

9p read ad/buffers/1/event | while read -r line; do
    echo "got event: $line"
    txt=$(echo "$line" | jq -r '.txt')
    if [ "$txt" = "README.md" ]; then
        echo "  > allowing event"
        echo "$line" | 9p write ad/buffers/1/event
    else
        echo "  > suppressing event"
    fi
done
Commit count: 823

cargo fmt