summaryrefslogtreecommitdiff
path: root/app/models
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'master' of https://dev.gitlab.org/gitlab/gitlabhqRémy Coutable2016-09-055-3/+7
|\ | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
| * Scope hooks thal will run for confidential issuesDouglas Barbosa Alexandre2016-08-312-0/+2
| |
| * Add option to confidential issues events to trigger servicesDouglas Barbosa Alexandre2016-08-313-3/+4
| |
| * Add option to confidential issues events to trigger WebhooksDouglas Barbosa Alexandre2016-08-311-0/+1
| |
* | Merge branch 'safe-ref-updates' into 'master' Douwe Maan2016-09-051-20/+21
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Safer ref updates Use `git update-ref` to prevent clobbering concurrent ref updates. If rugged/libgit2 is temporarily confused, due to concurrent `git gc` for example, then it used to be possible to accidentally reset a ref to an earlier state and lose commits. Because `git update-ref` does not get confused by `git gc`, what will happen now is that the commit based on confused information fails, preventing data loss. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/20353 See merge request !6130
| * | Make error message appropriate for end usersJacob Vosmaer2016-09-021-2/+2
| | |
| * | Use 'git update-ref' for safer web commitsJacob Vosmaer2016-09-021-20/+21
| | |
* | | Merge branch 'fix/handle-raw-trace-error-on-old-builds' into 'master' Douwe Maan2016-09-021-5/+22
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Handle error on trace raw download with old builds (DB stored) ## What does this MR do? Handles error on `raw build trace` download action for old builds (which are stored in DB instead of file). ## Are there points in the code the reviewer needs to double check? No. ## Why was this MR needed? At the beginning build traces were stored in database but at some point we moved to store them in files. All trace related actions are aware of this, but not `raw trace download`. ## What are the relevant issue numbers? Fixes #18900 ## 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)~~ - [ ] ~~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) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !4822
| * | Refactor Ci::Build#raw_tracefix/handle-raw-trace-error-on-old-buildsTomasz Maczukin2016-09-011-5/+2
| | |
| * | Update specs - add mocks to simulate old versionsTomasz Maczukin2016-09-011-1/+9
| | |
| * | Refactorize CI::Build modelTomasz Maczukin2016-09-011-2/+10
| | |
| * | Handle error on trace raw download with old builds (DB stored)Tomasz Maczukin2016-09-011-0/+4
| | |
* | | Merge branch 'sh-reload-find-branch' into 'master' Yorick Peterse2016-09-011-2/+15
|\ \ \ | | | | | | | | | | | | | | | | Optimize branch lookups and force a repository reload for Repository#find_branch See merge request !6087
| * | | Optimize branch lookups and force a repository reload for Repository#find_branchsh-reload-find-branchStan Hu2016-09-011-2/+15
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If `git gc` runs and `Repository` has an instance to `Rugged::Repository`, a bug in libgit2 may cause the instance to return a stale value or a missing branch. This change not only optimizes the branch lookup so we don't have to iterate through every branch, but it also works around the `git gc` issue by forcing a repository reload every time `Repository#find_branch` is called. See: https://github.com/libgit2/libgit2/issues/1534 Closes #15392, #21470
* | | Merge branch 'issue_19734' into 'master' Douwe Maan2016-09-014-11/+118
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Project tools visibility level ## part of #19734 ![project_features_access_level](/uploads/81ec7185d4e61d7578652020209af925/project_features_access_level.png) ## 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 !5606
| * | | Project tools visibility levelFelipe Artur2016-09-014-11/+118
| |/ /
* | | Merge branch 'js-tooltips-for-mentions' into 'master' Robert Speicher2016-09-012-16/+0
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use JavaScript tooltips for mentions ## What does this MR do? - use JavaScript tooltips instead of plain title for mentions (issue, merge request, snippet, user, group, commit, commit range, milestone) ## Why was this MR needed? JavaScript tooltips look nicer and can wrap. ## What are the relevant issue numbers? https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5261#note_13106713, fixes #21500 See merge request !5301
| * | | Use JavaScript tooltips for mentions (!5301)winniehell2016-09-012-16/+0
| | | |
* | | | Merge branch '20601-emoji-tooltip-in-chronological-order' into 'master' Robert Speicher2016-09-011-1/+1
|\ \ \ \ | |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | Order award tooltips by their created_at date ## What are the relevant issue numbers? Closes #20601 See merge request !6086
| * | | Order award tooltips by their created_at dateAndrew Smith2016-09-011-1/+1
| | | |
* | | | Merge branch 'refactor/add-policies' into 'master' Robert Speicher2016-08-314-583/+14
|\ \ \ \ | |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refactor ability.rb into Policies ## What does this MR do? Factors out `ability.rb` into a new abstraction - the "policy" (stored in `app/policies`). A policy is a class named `#{class_name}Policy` (looked up automatically as needed) that implements `rules` as follows: ``` ruby class ThingPolicy < BasePolicy def rules @user # this is a user to determine abilities for, optionally nil in the anonymous case @subject # this is the subject of the ability, guaranteed to be an instance of `Thing` can! :some_ability # grant the :some_ability permission cannot! :some_ability # ensure that :some_ability is not allowed. this overrides any `can!` that is called before or after delegate! @subject.other_thing # merge the abilities (can!) and prohibitions (cannot!) from `@subject.other_thing` can? :some_ability # test whether, so far, :some_ability is allowed end def anonymous_rules # optional. if not implemented `rules` is called where `@user` is nil. otherwise this method is called when `@user` is nil. end end ``` See merge request !5796
| * | | factor out a RuleSet so that `delegate!` retains @cannothttp://jneen.net/2016-08-301-1/+1
| | | |
| * | | remove the rest of the dead codehttp://jneen.net/2016-08-301-74/+0
| | | |
| * | | take the dive - only use abilities from Policieshttp://jneen.net/2016-08-301-8/+1
| | | |
| * | | port UserPolicyhttp://jneen.net/2016-08-301-11/+0
| | | |
| * | | port runners, namespaces, group/project_membershttp://jneen.net/2016-08-301-58/+0
| | | |
| * | | trim more dead codehttp://jneen.net/2016-08-301-52/+1
| | | |
| * | | port groupshttp://jneen.net/2016-08-301-36/+3
| | | |
| * | | port personal snippetshttp://jneen.net/2016-08-301-32/+1
| | | |
| * | | trim dead codehttp://jneen.net/2016-08-301-81/+0
| | | |
| * | | add automatic detection of the policy classhttp://jneen.net/2016-08-301-15/+3
| | | |
| * | | port CommitStatus/Buildhttp://jneen.net/2016-08-301-1/+2
| | | |
| * | | add and use MergeRequestPolicyhttp://jneen.net/2016-08-301-2/+5
| | | |
| * | | port issues to Issu{able,e}Policyhttp://jneen.net/2016-08-301-2/+4
| | | |
| * | | add support for anonymous abilitieshttp://jneen.net/2016-08-301-188/+6
| | | |
| * | | add policies, and factor out ProjectPolicyhttp://jneen.net/2016-08-301-31/+4
| | | |
| * | | remove Ability.abilitieshttp://jneen.net/2016-08-304-12/+3
| | | |
| * | | make almost everything on Ability privatehttp://jneen.net/2016-08-301-46/+44
| | | |
| * | | don't double-cache project_abiliteshttp://jneen.net/2016-08-301-11/+2
| | | |
| * | | remove six, and use a Set insteadhttp://jneen.net/2016-08-301-6/+19
| | | |
| * | | re-enable the cyclomatic complexity checkerhttp://jneen.net/2016-08-301-1/+0
| | | |
* | | | Merge branch 'remove-fishy-smell' into 'master' Douwe Maan2016-08-311-2/+2
|\ \ \ \ | |_|_|/ |/| | | | | | | | | | | | | | | | | | | Allow setting branch refs for MR @dbalexandre can you take a look please? See merge request !6025
| * | | Allow setting branch refs for MRremove-fishy-smellSean McGivern2016-08-251-2/+2
| | | |
* | | | Merge branch 'project-specific-lfs' into 'master' Robert Speicher2016-08-301-0/+7
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added project specific enable/disable setting for LFS ## What does this MR do? Adds project specific enable/disable setting for LFS ## What are the relevant issue numbers? Needed for #18092 See merge request !5997
| * | | | Renamed `enable_lfs` to `lfs_enabled` for the Project field, and related fixes.project-specific-lfsPatricio Cano2016-08-301-2/+2
| | | | |
| * | | | Syntax and style fixes.Patricio Cano2016-08-301-1/+4
| | | | |
| * | | | Added project specific enable/disable setting for LFSPatricio Cano2016-08-301-0/+4
| | |/ / | |/| |
* | | | Merge branch 'master' into prevent_authored_awardable_votesbarthc2016-08-307-29/+43
|\ \ \ \ | |/ / /
| * | | Merge branch 'artifacts-from-ref-and-build-name' into 'master' Douwe Maan2016-08-303-7/+14
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a download buttons for Build Artifacts ## What does this MR do? This MR adds a download buttons for build artifacts of latest succesful pipeline in: - dashboard of project, - branches and tags views, - and tree viewer Implement #4255 ## What are the relevant issue numbers? Closes #4255, Closes #14419 ## Screenshots ### Project main ![](/uploads/29ee2154a214416059a875f2715d4fa3/Screen_Shot_2016-08-24_at_8.00.31_PM.png) ### Branches ![](/uploads/9220c593288370986fbc1d42a1425ef7/Screen_Shot_2016-08-24_at_8.02.01_PM.png) ### Tags ![](/uploads/a843e8103221fea475a0cf9d62a1999d/Screen_Shot_2016-08-24_at_8.03.32_PM.png) ### Source Tree ![](/uploads/63cd3c8c91b6f427c166dc90d8e3c059/Screen_Shot_2016-08-24_at_8.04.56_PM.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] Download buttons - [x] Models - [x] Routes - [x] Projects::ArtifactsController - [x] API - Tests - Rails - [x] Project#builds_for - [x] branch name with slashes - [x] only success builds - [x] only latest builds - [x] feature tests for download buttons - API - [x] branch name with slashes - [x] only success builds - [x] only latest builds - [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 !5142
| | * \ \ Merge remote-tracking branch 'upstream/master' into ↵Lin Jen-Shin2016-08-2610-107/+153
| | |\ \ \ | | | | |/ | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | artifacts-from-ref-and-build-name * upstream/master: (107 commits) Fix external issue tracker "Issues" link leading to 404s Fix CHANGELOG entries related to 8.11 release. Fix changelog Reduce contributions calendar data payload Add lock_version to merge_requests table Add hover color to emoji icon Fix wrong Koding link Capitalize mentioned issue timeline notes Fix groups sort dropdown alignment Use icon helper Fix inline emoji text alignment Adds response mime type to transaction metric action when it's not HTML Moved two 8.11 changelog entries to 8.12 Fix markdown link in doc_styleguide.md Display project icon from default branch Reduce number of database queries on builds tab Update CHANGELOG Update Issue board documentation Label list shows all issues (opened or closed) with that label Update CHANGELOG ...