Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why wont Bash wait for read when used with Curl?

I wrote a Bash script to congfigure Git. It uses the read builtin, but when I do:

bash < <(curl -s https://raw.github.com/gist/419201/gitconfig.bash)

It doesn't wait for me to enter input. How do I get it to wait?

like image 467
ma11hew28 Avatar asked Sep 06 '25 00:09

ma11hew28


1 Answers

I tested it whitout the < as jcomeau_ictx suggested and it worked.

bash <(curl -s https://raw.github.com/gist/419201/gitconfig.bash | head -n 3)

Note: I used head -3 to stop execution after the read.

like image 71
Lynch Avatar answered Sep 07 '25 19:09

Lynch