Flutter Engine
The Flutter Engine
Public Member Functions | List of all members
env.api.EnvApi Class Reference
Inheritance diagram for env.api.EnvApi:

Public Member Functions

def __call__ (self, env_dict)
 

Detailed Description

Definition at line 9 of file api.py.

Member Function Documentation

◆ __call__()

def env.api.EnvApi.__call__ (   self,
  env_dict 
)

Definition at line 10 of file api.py.

10 def __call__(self, env_dict):
11 env = self.m.context.env
12 # If PATH is defined in both, merge them together, merging default_env into
13 # path by replacing %(PATH)s
14 upstream_path = env.get('PATH', '')
15 env.update(env_dict)
16 my_path = env_dict.get('PATH', '')
17 if upstream_path and my_path and upstream_path != my_path:
18 env['PATH'] = upstream_path.replace(r'%(PATH)s', my_path)
19
20 return self.m.context(env=env)

The documentation for this class was generated from the following file: