Long command in terminal.app cause a bug
I have a hunch that this is primarily caused by your accented characters (çã) in your directory name, because this is not a problem by default:



Special characters, unprintable or otherwise, frequently cause problems with classic terminals / shells.

Try opening a new terminal tab/window, and see if this problem occurs immediately, or if it doesn't occur until after you enter a directory with special characters.