Skip to content

Commit

Permalink
build: make it possible to pass a "--directory" arg to "git am" (#16024)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexeykuzmin committed Dec 11, 2018
1 parent 624ade2 commit 48abef2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion script/lib/git.py
Expand Up @@ -40,11 +40,13 @@ def get_repo_root(path):
return get_repo_root(parent_path)


def am(repo, patch_data, threeway=False,
def am(repo, patch_data, threeway=False, directory=None,
committer_name=None, committer_email=None):
args = []
if threeway:
args += ['--3way']
if directory is not None:
args += ['--directory', directory]
root_args = ['-C', repo]
if committer_name is not None:
root_args += ['-c', 'user.name=' + committer_name]
Expand Down

0 comments on commit 48abef2

Please sign in to comment.