Variables¶
- class getmac.variables.Variables[source]¶
Bases:
VarsClassThings that can change.
Essentially most of the global variables in getmac.
Attributes Summary
Cache of commands that have been checked for existence by
check_command().Name of the local host's default network interface.
Use a copy of the environment so any modifications that need to be made for operation of getmac doesn't modify the process's current environment.
Get and cache the configured system PATH environment variable on import.
The
PATHas a string.Global logger for getmac.
Attributes Documentation
-
CHECK_COMMAND_CACHE:
Dict[str,bool] = {}¶ Cache of commands that have been checked for existence by
check_command(). This speeds up subsequent lookups of the same command. The key is the command name, and the value is a boolean indicating if it exists.
-
ENV:
Dict[str,str]¶ Use a copy of the environment so any modifications that need to be made for operation of getmac doesn’t modify the process’s current environment.
-
PATH:
List[str]¶ Get and cache the configured system PATH environment variable on import. The process environment does not change after a process is started.
-
PATH_STR:
str¶ The
PATHas a string. Used for lookups bygetmac.utils.check_command(), which usesshutil.which()under the hood.
-
CHECK_COMMAND_CACHE: