1

I am trying to use a simple bash command to cause the sdiff of two curl requests

$ sdiff -l -w 140 $(curl -s "https:/URL/1/2/thing.php?d=20190202") \
                  $(curl -s "https:/URL/1/2/thing.php?d=20190203")

If I download the two curl requests into files, then sdiff the files it works. is it possible to consolidate into one command?

hek2mgl
  • 152,036
  • 28
  • 249
  • 266
Matt
  • 133
  • 1
  • 4
  • 13

1 Answers1

3

You can use process substitution:

sdiff ... <(curl ...) <(curl ...)
hek2mgl
  • 152,036
  • 28
  • 249
  • 266