moved script to one file