Bash – How to pass arguments to a script that is read via standard input

On Linux,

cat script.sh | bash /dev/stdin arguments

seems to work.

Leave a Comment