Scripting with Go

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

InfluxDB – Built for High-Performance Time Series Workloads
InfluxDB 3 OSS is now GA. Transform, enrich, and act on time series data directly in the database. Automate critical tasks and eliminate the need to move data externally. Download now.
www.influxdata.com
featured
Sevalla - Deploy and host your apps and databases, now with $50 credit!
Sevalla is the PaaS you have been looking for! Advanced deployment pipelines, usage-based pricing, preview apps, templates, human support by developers, and much more!
sevalla.com
featured
  1. murex

    A smarter shell and scripting environment with advanced features designed for usability, safety and productivity (eg smarter DevOps tooling)

    https://github.com/lmorg/murex

    (Don't be afraid to self promote!)

    One obvious benefit over what's suggested in the article is that you can use it interactively first, with autocomplete and such goodies, and transition smoothly to a script later.

  2. InfluxDB

    InfluxDB – Built for High-Performance Time Series Workloads. InfluxDB 3 OSS is now GA. Transform, enrich, and act on time series data directly in the database. Automate critical tasks and eliminate the need to move data externally. Download now.

    InfluxDB logo
  3. gorun

    gorun is a tool enabling one to put a "bang line" in the source code of a Go program to run it, or to run such a source code file explicitly. It was created in an attempt to make experimenting with Go more appealing to people used to Python and similar languages which operate most visibly with source code.

    I'll have to check this out properly later. 10 years ago go devs rejected the idea of introducing support hashbangs and now we're left with having to use gorun[0], meaning, people are unlikely to use go for script.

    I hope the go devs will reconsider. I'd love to be able to use go for scripting. But as it stands, it's a sad state of affairs because you have to rely on hacks.

    [0] https://github.com/erning/gorun/

  4. oils

    Oils is our upgrade path from bash to a better language and runtime. It's also for Python and JavaScript users who avoid shell!

    FWIW a lot of other host languages are more DSL-like, and have similar libraries:

    https://github.com/oilshell/oil/wiki/Internal-DSLs-for-Shell

    It looks like this particular one relies on method chaining

        script.Args().Concat().Match("Error").First(10).Stdout()

  5. script

    Making it easy to write shell-like scripts in Go

    It took me a while to find the link to the library "script" and it's repo - https://github.com/bitfield/script

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • 'script' is for writing shell-like pipelines in Go

    1 project | news.ycombinator.com | 28 Apr 2023
  • script

    1 project | /r/devopspro | 18 Jan 2023
  • Some Useful Patterns for Go's os/exec

    1 project | /r/golang | 29 Nov 2022
  • Is there anything golang similar to python plumbum?

    1 project | /r/golang | 17 Nov 2022
  • Planning to learn Go, does it have this feature?

    1 project | /r/commandline | 6 May 2022

Did you know that Go is
the 4th most popular programming language
based on number of references?