def execute(helper, config, args):
environments = []<EOL>if args.environment:<EOL><INDENT>for env_name in args.environment:<EOL><INDENT>environments.append(env_name)<EOL><DEDENT><DEDENT>else:<EOL><INDENT>for env_name, env_config in list(get(config, '<STR_LIT>').items()):<EOL><INDENT>environments.append(env_name)<EOL><DEDENT><DEDENT>wait_environments = []<EOL>for env_name in environments:<EOL><INDENT>env = parse_env_config(config, env_name)<EOL>option_settings = parse_option_settings(env.get('<STR_LIT>', {}))<EOL>helper.update_environment(env_name,<EOL>description=env.get('<STR_LIT:description>', None),<EOL>option_settings=option_settings,<EOL>tier_type=env.get('<STR_LIT>'),<EOL>tier_name=env.get('<STR_LIT>'),<EOL>tier_version=env.get('<STR_LIT>'))<EOL>wait_environments.append(env_name)<EOL><DEDENT>if not args.dont_wait:<EOL><INDENT>helper.wait_for_environments(wait_environments, health='<STR_LIT>', status='<STR_LIT>')<EOL><DEDENT>
Updates environments