diff --git a/interactive.bash b/interactive.bash index 5a9d4c7..694bf23 100755 --- a/interactive.bash +++ b/interactive.bash @@ -2,5 +2,13 @@ echo $- [[ $- == *i* ]] && echo 'Interactive' || echo 'Not interactive' + +if test -t 1; then + echo stdout +else + echo NO +fi + + read -p "Answer?: " echo $REPLY