move inline script into own file