あ,すいません。期待する動作は,
かりに理想のスクリプトを idea.sh として,
$ cat ./org.txt
2222
3333
1111
$ cat ./org.txt | idea.sh
3333
$ cat ./org.txt | sed -e '/3333/d' | idea.sh
2222
$ cat ./org.txt | sed -e '/3333/d' -e '/2222/d' | idea.sh
1111
という感じです。