Skip to content

Push with the --porcelain flag and parse output of failed pushes

Robert Speicher requested to merge rs-push-with-porcelain into master

Extracted from !1823 (closed), this enables --porcelain unconditionally and only logs the result of parsing that output after a failed push.

96df1115 - Add Gitlab::Git::PushResults class

Provides a simple interface to the output of git push --porcelain.

98012422 - Push with --porcelain flag

2929984a - Log details for a failed push_remote_branches call

We now take the output of the CommandError, which is the git push output, and run it through PushResults to see which branches were rejected and which were accepted.

A follow-up change will attempt to retry the push with only the accepted branches.

7eeb2563 - Add changelog for --porcelain flag

e66b20d6 - Simplify porcelain output parsing

By including the surrounding spaces in the split delimiter, we can avoid slicing and stripping.

f096ad02 - Avoid exceptions as control flow in push_remote_branches

Edited by GitLab Release Tools Bot

Merge request reports

Loading