Skip to content

Instantly share code, notes, and snippets.

@pigreco
Last active April 3, 2016 10:12
Show Gist options
  • Save pigreco/42950c34bfeaac32ea483aeba8bed07b to your computer and use it in GitHub Desktop.
Save pigreco/42950c34bfeaac32ea483aeba8bed07b to your computer and use it in GitHub Desktop.
status = repo.git.status()
untracked_files = []
for l in status.split('\n'):
if l.strip().startswith('python/plugins'):
untracked_files.append(l.strip())
untracked_files.append(definition_file)
author = Actor('Author', email)
committer = Actor ('Committer', email)
index = repo.index
index.add([f for f in untracked_files])
index.commit('[processing-test] ' + commit_message, author=author, committer=committer)
origin.push(refspec=heads.new_branch)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment