changed the way options are passed to scripts