def flow_init(
     self, flow, graph, environment, flow_datastore, metadata, logger, echo, options
 ):
     self._option_values = options
     project_name = self.attributes.get("name")
     project_flow_name, branch_name = format_name(
         flow.name,
         project_name,
         options["production"],
         options["branch"],
         get_username(),
     )
     is_user_branch = options["branch"] is None and not options["production"]
     echo(
         "Project: *%s*, Branch: *%s*" % (project_name, branch_name),
         fg="magenta",
         highlight="green",
     )
     current._update_env(
         {
             "project_name": project_name,
             "branch_name": branch_name,
             "is_user_branch": is_user_branch,
             "is_production": options["production"],
             "project_flow_name": project_flow_name,
         }
     )
     metadata.add_sticky_tags(
         sys_tags=["project:%s" % project_name, "project_branch:%s" % branch_name]
     )
Beispiel #2
0
 def flow_init(self, flow, graph, environment, datastore, logger, echo,
               options):
     self._option_values = options
     project_name = self.attributes.get('name')
     project_flow_name, branch_name = format_name(flow.name, project_name,
                                                  options['production'],
                                                  options['branch'],
                                                  get_username())
     is_user_branch = options['branch'] is None and not options['production']
     echo("Project: *%s*, Branch: *%s*" % (project_name, branch_name),
          fg='magenta',
          highlight='green')
     current._update_env({
         'project_name': project_name,
         'branch_name': branch_name,
         'is_user_branch': is_user_branch,
         'is_production': options['production'],
         'project_flow_name': project_flow_name
     })
Beispiel #3
0
 def flow_init(self, flow, graph, environment, flow_datastore, logger, echo,
               options):
     current._update_env({'foobar_value': options['foobar']})
Beispiel #4
0
 def flow_init(self, flow, graph, environment, flow_datastore, metadata,
               logger, echo, options):
     current._update_env({"foobar_value": options["foobar"]})