summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Added path parameter to Commits APILuis HGO2016-10-241-0/+2
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Merge branch '21513-fix-branch-protection-api' into 'master' Douwe Maan2016-10-241-33/+15
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix branch protection API. ## What does this MR do? - Fixes the branch protection API. - Closes #21513 - EE Merge Request: gitlab-org/gitlab-ee!718 ## Tasks - [ ] #21513 !6215 Protected branches API bug - [x] Investigate - [x] Test + Fix - [x] Changelog - [x] MR - [x] Wait for build to pass - [x] Review - [x] Check for EE conflicts - [x] Create EE MR - [x] Refactor + Fix - [x] Rebase EE MR against EE master - [x] Wait for builds to pass - [x] Assign to dbalexandre/douwe - [x] Implement latest review comments - [x] Wait for Douwe's review - [x] Implement changes - [x] Port changes to EE MR - [x] Assign both back to Douwe - [ ] Wait for merge - [ ] Merge gitlab-org/gitlab-ee!718 See merge request !6215
| * Implement second round of review comments from @DouweM.Timothy Andrew2016-10-241-6/+3
| | | | | | | | | | | | | | - Pass `developers_and_merge` and `developers_can_push` in `params` instead of using keyword arguments. - Refactor a slightly complex boolean check to a simple `nil?` check.
| * Implement review comments from @DouweM.Timothy Andrew2016-10-241-2/+2
| |
| * Fix branch protection API.Timothy Andrew2016-10-241-31/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Previously, we were not removing existing access levels before creating new ones. This is not a problem for EE, but _is_ for CE, since we restrict the number of access levels in CE to 1. 2. The correct approach is: CE -> delete all access levels before updating a protected branch EE -> delete developer access levels if "developers_can_{merge,push}" is switched off 3. The dispatch is performed by checking if a "length: 1" validation is present on the access levels or not. 4. Another source of problems was that we didn't put multiple queries in a transaction. If the `destroy_all` passes, but the `update` fails, we should have a rollback. 5. Modifying the API to provide users direct access to CRUD access levels will make things a lot simpler. 6. Create `create/update` services separately for this API, which perform the necessary data translation, before calling the regular `create/update` services. The translation code was getting too large for the API endpoint itself, so this move makes sense.
* | Add relative url support to routing contrainersDmitriy Zaporozhets2016-10-241-1/+12
|/ | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* Merge branch 'sh-fix-broken-label-controller' into 'master' Rémy Coutable2016-10-221-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | Fix error in generating labels Attempting to generate default set of labels would result in an error: ArgumentError: wrong number of arguments (given 1, expected 0) Closes #23649 See merge request !7055
| * Fix error in generating labelssh-fix-broken-label-controllerStan Hu2016-10-221-1/+1
| | | | | | | | | | | | | | | | | | Attempting to generate default set of labels would result in an error: ArgumentError: wrong number of arguments (given 1, expected 0) Closes #23649
* | Merge branch '23653-dont-clear-db-cache-every-release' into 'master' Yorick Peterse2016-10-221-1/+1
|\ \ | | | | | | | | | | | | Stop clearing the database cache on rake cache:clear See merge request !7056
| * | Stop clearing the database cache on rake cache:clearNick Thomas2016-10-221-1/+1
| |/
* | Fix documents and comments on Build API `scope`. #23146 #19131Lemures Lemniscati2016-10-221-2/+2
|/
* Merge branch ↵Valery Sizov2016-10-211-0/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | '12622-backup-restore-doesn-t-clear-cache-resulting-in-missing-branches-and-tags' into 'master' Fix: Backup restore doesn't clear cache ## What does this MR do? Clears cache when we do backup restoring. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/12622 ## What are the relevant issue numbers? https://gitlab.com/gitlab-org/gitlab-ce/issues/12622 See merge request !7019
| * Fix: Backup restore doesn't clear cache12622-backup-restore-doesn-t-clear-cache-resulting-in-missing-branches-and-tagsValery Sizov2016-10-201-0/+2
| |
* | Don't use Hash#slice since it's not supported in Ruby 2.1fix-ruby-2-1-failuresRémy Coutable2016-10-201-3/+8
| | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | Merge remote-tracking branch 'upstream/master' into ↵preserve-note_type-and-positionLin Jen-Shin2016-10-202-7/+10
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | preserve-note_type-and-position * upstream/master: Restrict ProjectCacheWorker jobs to one per 15 min Removed code from project members controller Make label API spec independent of order Refactoring find_commits functionality Differentiate the expire from leave event Remove pagination description from individual doc Fix a broken table in Project API doc Create project feature when project is created Simpler arguments passed to named_route on toggle_award_url helper method Fixed height of issue board blank state
| * Merge branch 'refactoring_find_commits_method' into 'master' Sean McGivern2016-10-201-5/+1
| |\ | | | | | | | | | | | | | | | | | | Refactoring find_commits method It's possible that `find_commits_by_message` return nil in array which is not OK. We have different checks outside of this method. This MR places all checks inside the method. See merge request !7000
| | * Refactoring find_commits functionalityValery Sizov2016-10-201-5/+1
| | |
| * | Differentiate the expire from leave eventCallum Dryden2016-10-201-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At the moment we cannot see weather a user left a project due to their membership expiring of if they themselves opted to leave the project. This adds a new event type that allows us to make this differentiation. Note that is not really feasable to go back and reliably fix up the previous events. As a result the events for previous expire removals will remain the same however events of this nature going forward will be correctly represented.
* | | Preserve note_type and position for notes from emailsLin Jen-Shin2016-10-201-1/+3
|/ / | | | | | | Closes #23208
* | Merge branch 'feature/group-level-labels' into 'master' Douwe Maan2016-10-1916-81/+160
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add group level labels ## What does this MR do? Add group level labels. ## Are there points in the code the reviewer needs to double check? * `LabelsFinder` * `Gitlab::Gfm::ReferenceRewriter` * `Banzai::Filter::LabelReferenceFilter` ## Why was this MR needed? We'll be adding more feature that allow you to do cross-project management of issues. ## Screenshots (if relevant) * Group Labels ![Group Labels](/uploads/2244c06ad68eae4fb246fb4c81bf8060/2.png) * Project Labels ![Project Labels](/uploads/c5839516d2282b51f7418d9dadbeceb4/1.png) * Expanded references for group labels when moving issue to another project ![Expanded references for group labels when moving issue to another project](/uploads/0c9ab248a8420d4978d59349ae3d42e5/3.png) ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [ ] [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 - [ ] All builds are passing - [ ] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [ ] 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) ## What are the relevant issue numbers? #19997 See merge request !6425
| * | Use LabelsFinder on Fogbuz importerDouglas Barbosa Alexandre2016-10-191-1/+2
| | |
| * | Use LabelsFinder on Google Code importerDouglas Barbosa Alexandre2016-10-191-1/+2
| | |
| * | Rename Labels::CreateService to Labels::FindOrCreateServiceDouglas Barbosa Alexandre2016-10-194-4/+4
| | |
| * | Update specs to cope with new label types and prioritiesJames Lopez2016-10-194-12/+27
| | | | | | | | | | | | | | | | | | Fixed all related specs and also changed the logic to handle edge cases. This includes exporting and exporting of group labels, which will get associated with the new group (if any) or they will become normal project labels otherwise. Found other issues to do with not being able to import all labels at once in the beginning of the JSON - code was much simpler when we import all labels and milestones associated to a project first, then the associations will find the already created labels instead of creating them from the associations themselves.
| * | Fix GitHub importer specDouglas Barbosa Alexandre2016-10-191-1/+4
| | |
| * | User Labes::CreateService to create labelsDouglas Barbosa Alexandre2016-10-194-9/+10
| | |
| * | Reuse LabelsFinder on Banzai::Filter::LabelReferenceFilterDouglas Barbosa Alexandre2016-10-191-7/+1
| | |
| * | Remove Issuable#add_labels_by_namesDouglas Barbosa Alexandre2016-10-192-26/+18
| | |
| * | List all available labels to the project on the labels APIDouglas Barbosa Alexandre2016-10-191-1/+1
| | |
| * | Add support to group labels on issues board APIDouglas Barbosa Alexandre2016-10-191-2/+2
| | |
| * | Validate label params against all labels available to project on the APIDouglas Barbosa Alexandre2016-10-191-10/+9
| | |
| * | Move label management to services on merge requests APIDouglas Barbosa Alexandre2016-10-191-11/+4
| | |
| * | Keep cross project reference logic in GroupLabel#to_referenceDouglas Barbosa Alexandre2016-10-191-9/+1
| | |
| * | Fix replace label references with links for group labelsDouglas Barbosa Alexandre2016-10-191-1/+7
| | |
| * | Use try instead of ternary operator on Gitlab::ImportExport::ProjectTreeRestorerDouglas Barbosa Alexandre2016-10-191-2/+1
| | |
| * | Reuse LabelsFinder on Issueable#add_labels_by_namesDouglas Barbosa Alexandre2016-10-193-4/+4
| | |
| * | Reuse LabelsFinder on Banzai::Filter::LabelReferenceFilterDouglas Barbosa Alexandre2016-10-191-7/+5
| | |
| * | Fix import/export labels to cope with project and group labels. Added ↵James Lopez2016-10-194-5/+26
| | | | | | | | | | | | relevant specs.
| * | Fix import testJames Lopez2016-10-192-3/+6
| | |
| * | Unfold references for group labels when moving issue to another projectDouglas Barbosa Alexandre2016-10-192-4/+53
| | |
| * | Add Lavel#type to methods in lib/gitlab/import_export/import_export.ymlDouglas Barbosa Alexandre2016-10-191-0/+2
| | |
| * | Add ProjectLabel modelDouglas Barbosa Alexandre2016-10-192-2/+2
| | |
| * | Replace label references with links for group labelsDouglas Barbosa Alexandre2016-10-191-3/+13
| | |
* | | Merge branch 'issue_828' into 'master' Douwe Maan2016-10-193-15/+38
|\ \ \ | |/ / |/| | | | | | | | | | | | | | Prevent wrong markdown on issue ids when project has Jira service activated fixes gitlab-org/gitlab-ee#828 See merge request !6728
| * | Prevent wrong markdown on issue ids when project has Jira service activatedissue_828Felipe Artur2016-10-193-15/+38
| | |
* | | Merge branch 'fix-escaping' into 'master' Sean McGivern2016-10-191-1/+1
|\ \ \ | |/ / |/| | | | | | | | fix: commit messages being double-escaped in activities tab See merge request !6937
| * | fix: commit messages being double-escaped in activies tabamaia2016-10-181-1/+1
| | |
* | | Merge branch 'grapify-commit-statuses-api' into 'master' Rémy Coutable2016-10-191-26/+27
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Grapify the commit status API ## What does this MR do? Add the Grape-DSL to the commit status API. ## What are the relevant issue numbers? Related to #22928 See merge request !6879
| * | | Grapify the commit status APIgrapify-commit-statuses-apiRobert Schilling2016-10-191-26/+27
| | | |
* | | | Merge branch 'fix-system-hook-api' into 'master' Rémy Coutable2016-10-191-6/+4
|\ \ \ \ | |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | API: Fix Sytem hooks delete behavior ## What does this MR do? This corrects the delete API for system hooks. Returning 200 is not the right way indicating a hooks is not found. ## What are the relevant issue numbers? Discussed in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/6861/diffs#609af00c90e3d5241064d1404e3e018a3235634a_64_62 See merge request !6883