ed.py: fix extra blank line after appended text
fix sample_read.sh test script, add missing q command