git-codereview: factor submitting a single change

This factors the logic for committing a single change in preparation
for supporting submitting multiple changes at once.

Change-Id: Ida083ada2c3a5393f99159e588dbc87af3902091
Reviewed-on: https://go-review.googlesource.com/16673
Reviewed-by: Andrew Gerrand <adg@golang.org>
1 file changed