bash - Send string to stdin -
is there way in bash:
/my/bash/script < echo 'this string sent stdin.' i'm aware pipe output echo such this:
echo 'this string piped stdin.' | /my/bash/script
you can use one-line heredoc
cat <<< "this coming stdin" the above same as
cat <<eof coming stdin eof or can redirect output command, like
diff <(ls /bin) <(ls /usr/bin) or can read as
while read line echo =$line= done < some_file or simply
echo | read param
Comments
Post a Comment