put script into main