• Home
  • Raw
  • Download

Lines Matching refs:directory

99 def git_repository_sync_is_disabled(git, directory):  argument
102 [git, 'config', 'sync-deps.disable'], cwd=directory)
108 def is_git_toplevel(git, directory): argument
119 [git, 'rev-parse', '--show-toplevel'], cwd=directory).strip()
120 return os.path.realpath(bytes(directory, 'utf8')) == os.path.realpath(toplevel)
125 def status(directory, checkoutable): argument
129 directory = truncate(directory, dlen)
131 sys.stdout.write('%-*s @ %s\n' % (dlen, directory, checkoutable))
134 def git_checkout_to_directory(git, repo, checkoutable, directory, verbose): argument
153 if not os.path.isdir(directory):
155 [git, 'clone', '--quiet', repo, directory])
157 if not is_git_toplevel(git, directory):
160 sys.stdout.write('%s\n IS NOT TOP-LEVEL GIT DIRECTORY.\n' % directory)
164 if git_repository_sync_is_disabled(git, directory):
165 sys.stdout.write('%s\n SYNC IS DISABLED.\n' % directory)
172 cwd=directory, stderr=devnull):
175 status(directory, checkoutable) # Success.
181 [git, 'remote', 'set-url', 'origin', repo], cwd=directory)
183 subprocess.check_call([git, 'fetch', '--quiet'], cwd=directory)
185 subprocess.check_call([git, 'checkout', '--quiet', checkoutable], cwd=directory)
188 status(directory, checkoutable) # Success.
224 for directory in dependencies:
226 if directory.startswith(other_dir + '/'):
227 raise Exception('%r is parent of %r' % (other_dir, directory))
229 for directory in sorted(dependencies):
230 if '@' in dependencies[directory]:
231 repo, checkoutable = dependencies[directory].split('@', 1)
235 relative_directory = os.path.join(deps_file_directory, directory)
242 for directory in deps_file.get('recursedeps', []):
243 recursive_path = os.path.join(deps_file_directory, directory, 'DEPS')