Sha256: df0499750f870ad3c6b05fd5ec41f43020cf32cf4996250fd786eea73c571b20

Contents?: true

Size: 1001 Bytes

Versions: 30

Compression:

Stored size: 1001 Bytes

Contents

# Copyright 2016 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

from recipe_engine import recipe_api


class InfraPathsApi(recipe_api.RecipeApi):
  """infra_paths module is glue for design mistakes. It will be removed."""

  def initialize(self):
    path_config = self.m.properties.get('path_config')
    if path_config:
      # TODO(phajdan.jr): remove dupes from the engine and delete infra_ prefix.
      self.m.path.set_config('infra_' + path_config)

  @property
  def default_git_cache_dir(self):
    """Returns the location of the default git cache directory.

    This property should be used instead of using path['git_cache'] directly.

    It returns git_cache path if it is defined (Buildbot world), otherwise
    uses the more generic [CACHE]/git path (LUCI world).
    """
    try:
      return self.m.path['git_cache']
    except KeyError:
      return self.m.path['cache'].join('git')

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
libv8-7.8.279.23.0beta1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-7.4.288.28.0beta1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-7.3.492.27.3beta1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-7.3.492.27.1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-7.3.492.27.0 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-7.3.492.27.0beta1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.7.288.46.1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.7.288.46.0 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.7.288.46.1beta0 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.3.292.48.1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.3.292.48.0 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.3.292.48.0beta2 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.3.292.48.0beta1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.2.414.42.1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.2.414.42.0 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.2.414.42.0beta1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.0.286.54.3 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.0.286.54.2 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.0.286.54.1 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py
libv8-6.0.286.54.0 vendor/depot_tools/recipes/recipe_modules/infra_paths/api.py