this post was submitted on 17 Feb 2025
6 points (87.5% liked)
Bash
812 readers
1 users here now
Talk about the Bash Shell and Bash scripting
founded 4 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Wild, I get
syntax error: unexpected end of file
when I run your code, so just that alone is very confusing.When you're inside
foo
here, STDIN is the pipe. Once I fix this syntax error that you somehow dodge and add some extra debugging, you can get a better picture of what's going on here:Sorry, I've dropped
done
by mistake when I pasted my snippet.And thanks for your explanation, but I didn't fully understand how this happened.