fstrm_dump(1)

✨ NAME ✨

okay bestie, gather round πŸ’– this is fstrm_dump from the General Commands Manual (section 1, the command-line girlies) β€” she displays the metadata and contents of a Frame Streams file. that's the whole job. she's giving ✨ inspector energy ✨ and honestly? iconic.


🌸 SYNOPSIS 🌸

fstrm_dump input-file [output-file]

like. that's it. two little slots. no cap.


πŸ’… DESCRIPTION πŸ’…

so here's the tea πŸ«– β€” fstrm_dump opens up input-file and then splits the info like a true main character: it prints the framing metadata to stderr, and the frame data to stdout. two different streams, two different vibes, no crossover drama.

and listen β€” input-file can literally just be "-" and she'll read the Frame Streams data from standard input instead. the way that just works?? obsessed. 😭

frame data comes out as a single line quoted string, and every non-printable character gets replaced by a backslash-prefixed hex escape sequence. for example, a frame containing "Hello, world\n" would have its data printed as:

"Hello, world\x0a"

see how the newline became \x0a? she's not hiding anything, she's just making it printable. very demure, very mindful πŸŽ€

the only framing metadata she expects to find in a Frame Streams file is the start frame with a content type field, the data frame lengths, and the stop frame. and those get printed, respectively, as:

FSTRM_CONTROL_START

FSTRM_CONTROL_FIELD_CONTENT_TYPE (N bytes)
 "content-type"

Data frame (N) bytes

FSTRM_CONTROL_STOP

look at that little lineup πŸ₯Ή FSTRM_CONTROL_START kicking things off, the FSTRM_CONTROL_FIELD_CONTENT_TYPE (N bytes) with its "content-type" string riding along, the Data frame (N) bytes doing the actual work in the middle, and FSTRM_CONTROL_STOP closing the curtain. periodt. πŸ‘‘

okay but here's the part where you pay attention bestie β€” if fstrm_dump gets that second output-file parameter, the input frames are additionally written to output-file too. this is mainly useful for regression testing of the fstrm_file_writer code. so she's not just reading, she's also writing a copy. multitasking queen fr fr πŸ’œ

πŸ”₯ SEE ALSO πŸ”₯


and that's the whole page babes πŸ¦‹ this was fstrm_dump(1) from the General Commands Manual β€” go forth, dump some frames, and slay πŸ’–βœ¨πŸŽ€