Put entire script inside anonymous function