News for hackers. Stuff that matters.
Re:Scripting with Go: A Modest Proposal by simonw on Sunday August 20, 2023 @11:03AM (#37199844)
I believe error handling looks like this:

    package main

    import (
        "github.com/bitfield/script"
    )

    func main() {
         _, err := script.Stdin().Column(1).Freq().First(10).Stdout()
        if err != nil {
            log.Fatal(err)
        }
    }
Errors are "remembered" by the pipeline and can be processed when you get to a sink method.

There are no comments on this comment yet.