GitLab hooks: sending hg_prune payload
We need to serialize the hg_prune field itself as JSON, since the GitLab internal API would accept only plain string as values on the other side (or we'd have to go to great length with the `Hash` param type to produce the flexibility we need). GitLab branch names are received as bytes and output as base64 in the resulting payload, leaving the burden to guess the encoding to the Rails application. This is less cowardly as it sounds: on the Rails side, there's already a layer of decoding and encoding guesswork for the `changes` parameter (identical to a Git post-receive stdin payload). Hence, we'll be able to use the same system for consistent results.
parent
561605221ea1
No related branches found
No related tags found
Loading
Please register or sign in to comment