I'd like something in the form of (fill in the blanks):
cmd1 | ____ cmd2 ____ That was equivalent to this, but without writing any files:
cmd1 > temp cmd2 < temp | diff temp - cmd1 isn't actually a command, it's a stdin stream from a text editor, so it cannot be run more than once, so this won't work:
diff <(cmd1) <(cmd1 | cmd2) But that is essentially what I want.
I'm using macOS, but I'd prefer it linux compatible as well.
cmd1needs to be stored somewhere for it to be able to be processed by bothcmd2anddiff.