Pipexec – Handling pipe of commands like a single command

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

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • pipexec

    Handling pipe of commands like a single command

  • dgsh

    Shell supporting pipelines to and from multiple processes

  • Hm interesting, also see dgsh, the directed graph shell

    https://www2.dmst.aueb.gr/dds/sw/dgsh/

    https://github.com/dspinellis/dgsh

    https://news.ycombinator.com/item?id=21700014

    dgsh uses Unix domain sockets, not pipes. I don't remember exactly why, but it's in the paper, perhaps to avoid deadlocks compared to pipes.

    I'd also be interested in some more examples with pipexec or dgsh!

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • rustexercises

    Discontinued Computer Science Open Courseware Material applied to Rust

  • This reminds me of MIT's open courseware, 601 SC, unit 1 with state machines, going all the way to build Fibonacci with them without recursion, tbh the moment the teacher translated the state machine to bounds to electrical circuit I felt it was a leap and I couldn't quite understand their relationship, maybe I missed a requirement course. I tried to express that course in Rust as one of my first projects learning the language here https://github.com/sebosp/rustexercises/blob/develop/ocw601s... and I think a similar iteration in the direction of this project would be to build the dependencies as drag-and-drop boxes over the browser (maybe egui) and connect the state machines by clicks, maybe download the generated code as either bash or compilable rust code, you know, for kids.

  • websocketd

    Turn any program that uses STDIN/STDOUT into a WebSocket server. Like inetd, but for WebSockets.

  • Somewhat related: https://github.com/joewalnes/websocketd

    > websocketd is a small command-line tool that will wrap an existing command-line interface program, and allow it to be accessed via a WebSocket.

  • oil

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

  • No other shell does that.

    But I didn't know it was called MULTIOS until now. (I guess that's read "mult I/O's"? I have a hard time not reading it was multi-OS :) )

    It seems a bit niche to be honest, but it's possible to support in Oils.

    ---

    Oils also uses Unix domain sockets already for the headless shell protocol

    https://github.com/oilshell/oil/wiki/Headless-Mode

    We could do something like dgsh, but so far I haven't seen a lot of uptake / demand. Every time it's mentioned, somebody kinda wants it, and then it kinda peters out again ... still possible though.

    I think flat files work fine for a lot of use cases, and once you add streaming, you also want monitoring, more control over backpressure/queue sizes, etc.

  • moreutils

    moreutils is a growing collection of the unix tools that nobody thought to write long ago when unix was young. Read-only version of `git://git.joeyh.name/moreutils`

  • I use mutlios and even I'm not that attached to it. The majority of my use is combined with process substitution, and could be replaced with common-ish tools like pee¹ or pipexec for more complex cases. The only occasion when I'm thankful for it is if I want to use a shell function as a target, but there are workarounds for that too.

    As a noclobber user the footgun is largely hidden to me, but I feel its presence. multios without globbing support would be less useful, but would still work for most of my use cases. Scanning my shell history I see various cases of relying on zsh's ability to apply sorting and filtering to globs with multios' input redirection, but only a couple where I want that in output redirection.

    Even with multios unset the behaviour is different between zsh and bash. For example, multios disables all the expansion, so zsh behaves like more like dash with ': >t{1,2}' by creating a file instead producing an error like bash does.

    [FWIW, I google'd multiios to link the option in original comment. It really feels to me like it needs double-i, and I read the single i name the same way you do.]

    ---

    I'd be one of those people whose desire for dgsh-like functionality wanes. If it was slight DSL that I could "upgrade" pipelines to I'd probably use it, but not enough to warrant working on it or switching other tooling to support it.

    The end of result of this morning's pipeline was breaking my jobs up, and applying some judicious use of nq² to keep track of it. I'd follow your advice and move on to more specialist tools if the job grew significantly or if it became a regular occurrence.

    ¹ https://joeyh.name/code/moreutils/

    ² https://git.vuxu.org/nq/about/

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