gitlab-org--gitlab-foss/lib
Rémy Coutable d6bd412be4 Merge branch 'api-dev-can-push' into 'master'
API: Expose 'developers_can_push' for branches

## What does this MR do?

Adds support for the `developers_can_push` flag for the branches API. It also supports creating protected branches with that flag.

## Are there points in the code the reviewer needs to double check?

The API call requires an optional boolean parameter `developers_can_push`. If it is not either `true` or `false`, it should not update the value. I'm not sure if this is the right way to do it.

Right now it always returns `200`. Maybe the `PUT` method should return different status codes depending if it really created or updated a branch.

## What are the relevant issue numbers?

Closes #12735 

## Does this MR meet the acceptance criteria?

- [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added
- [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)
- [x] API support added
- Tests
  - [x] Added for this feature/bug
  - [x] All builds are passing
- [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides)
- [x] Branch has no merge conflicts with `master` (if you do - rebase it please)
- [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits)

See merge request !5208
2016-07-19 10:31:56 +00:00
..
api Only update once 2016-07-19 11:33:47 +02:00
assets
backup Refactor repository paths handling to allow multiple git mount points 2016-06-29 22:30:31 -04:00
banzai Don't parse Rinku returned value to DocFragment when it didn't change the original html string. 2016-07-18 13:11:46 +02:00
ci Store when and yaml variables in builds table 2016-07-16 20:25:30 +02:00
container_registry Make rubocop happy 2016-07-15 18:05:39 +02:00
gitlab Squashed - fix encoding issue 2016-07-19 09:59:54 +02:00
json_web_token Revert "Fix merge conflicts - squashed commit" 2016-06-03 11:10:17 +02:00
omni_auth
rouge/formatters use %(...) and %[...] in favor of %<...> 2016-07-14 22:43:49 -07:00
support Defend against 'Host' header injection 2016-07-12 19:50:20 +02:00
tasks Upgrade Gemojione from 2.6.1 to 3.0.1. 2016-07-18 10:40:16 -06:00
banzai.rb Object renderer read_multi rendered entries from Cache 2016-07-12 14:35:29 +02:00
disable_email_interceptor.rb Enable Style/EmptyLines cop, remove redundant ones 2016-07-01 21:56:17 +02:00
event_filter.rb Revert "Fix merge conflicts - squashed commit" 2016-06-03 11:10:17 +02:00
extracts_path.rb
file_size_validator.rb Get rid of more requires, which causes warnings when code is reloaded 2016-04-19 11:48:10 +02:00
file_streamer.rb
gitlab.rb Update `Gitlab.com?` to support staging 2016-06-27 15:10:36 -04:00
gt_one_coercion.rb
repository_cache.rb
static_model.rb
unfold_form.rb
uploaded_file.rb Enable Style/EmptyLines cop, remove redundant ones 2016-07-01 21:56:17 +02:00
version_check.rb