Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Distro specific branches #107

Merged
merged 3 commits into from
Dec 28, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions superflore/generators/bitbake/ros_meta.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,6 @@ def commit_changes(self, distro):
info('Committing to branch {0}...'.format(self.branch_name))
self.repo.git.commit(m='{0}'.format(commit_msg))

def pull_request(self, message):
def pull_request(self, message, distro):
pr_title = 'rosdistro sync, {0}'.format(time.ctime())
self.repo.pull_request(message, pr_title)
self.repo.pull_request(message, pr_title, branch=distro)
6 changes: 3 additions & 3 deletions superflore/generators/bitbake/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@
overlay = None


def file_pr(overlay, delta, missing_deps):
def file_pr(overlay, delta, missing_deps, distro):
try:
overlay.pull_request('{0}\n{1}'.format(delta, missing_deps))
overlay.pull_request('{0}\n{1}'.format(delta, missing_deps), distro)
except Exception as e:
err('Failed to file PR with allenh1/meta-ros repo!')
err(' Exception: {0}'.format(e))
Expand Down Expand Up @@ -163,5 +163,5 @@ def main():

# Commit changes and file pull request
overlay.commit_changes(args.ros_distro)
file_pr(overlay, delta, missing_deps)
file_pr(overlay, delta, missing_deps, args.ros_distro)
ok('Successfully synchronized repositories!')
10 changes: 7 additions & 3 deletions superflore/repo_instance.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,14 @@ def rebase(self, target):
"""
self.git.rebase(i=target)

def pull_request(self, message, title):
def pull_request(self, message, title, branch='master', remote='origin'):
info('Filing pull-request...')
self.git.pull_request(m='{0}'.format(message),
title='{0}'.format(title))
self.git.pull_request(
m='{0}'.format(message),
title='{0}'.format(title),
target_branch='{0}'.format(branch),
target_remote='{0}'.format(remote),
)
ok('Successfully filed a pull request.')


Expand Down