# Set an environment variable for all userswin_environment:state:presentname:TestVariablevalue:Test valuelevel:machine# Remove an environment variable for the current userswin_environment:state:absentname:TestVariablelevel:user
This module is best-suited for setting the entire value of an environment variable. For safe element-based management of path-like environment vars, use the win_path module.
This module does not broadcast change events. This means that the minority of windows applications which can have their environment changed without restarting will not be notified and therefore will need restarting to pick up new environment settings. User level environment variables will require the user to log out and in again before they become available.