wrapping global usage in script