Show HN: Chez Scheme txtar port from Go

74 points by hellcow 5 months ago | 8 comments
This is a loose port of https://golang.org/x/tools/txtar, which concatenates files together and allows for a top-level comment.

The txtar format is specifically designed to be easy for humans to read and write by hand. It's perfect for test data.

The library itself tries to follow scheme standards by depending on only SRFIs (and if you're new to scheme like me, SRFI stands for "Scheme Requests For Implementation," and it's like a standard library). I hope this is a helpful showcase of a scheme library!

I'm also new to writing scheme, and if any experienced scheme/lisp devs are out there with feedback, that would be much appreciated.

  • thaliaarchi 5 months ago
    Simple format. Makes me want to write a parser for it using a shared buffered reader library I’m working on in Rust.
  • shawn_w 5 months ago
    The Go version treats file data as byte arrays; might want to do the same and use Scheme bytevectors instead of strings. OTOH the docs say it's not supposed to be a general binary format...
    • ewired 5 months ago
      • philkrylov 5 months ago
        hrx looks much better, as txtar can't include, e.g., other txtar files
      • sudahtigabulan 5 months ago
        The Markdown of archives.
        • tyho 5 months ago
          I have been using txtar to provide context to LLM's recently.
          • rtcode_io 5 months ago
            [flagged]