If I enter bash -x option, it will show all the line. But the script will execute normaly.
How can I execute line by line? Than I can see if it do the correct thing,
Have a look at bash-stepping-xtrace.
It allows stepping xtrace.