Commit Graph
23875 Commits
Author SHA1 Message Date
Jacob Vosmaer 24fa458615 Use /raw/ requests for image diffs 2016-02-16 17:29:45 +01:00
Jacob Vosmaer 15126fc70f Fix SVG blob rendering 2016-02-16 17:01:25 +01:00
Douwe Maan bbbfdba0b9 Merge branch 'bugagazavr/gitlab-ce-extend-hooks' into 'master'
Add new data to project in push, issue, merge-request and note webhooks data

_Originally opened at !2738 by @bugagazavr._

- - -

**What does this MR do?**

Adds more data to hooks, makes repository data in all hook more dry ( use one hook_attrs method for repository data in all hooks )

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

1. https://gitlab.com/bugagazavr/gitlab-ce/blob/extend-hooks/app/models/project.rb#L738
2. https://gitlab.com/bugagazavr/gitlab-ce/blob/extend-hooks/app/models/concerns/issuable.rb#L132
3. https://gitlab.com/bugagazavr/gitlab-ce/blob/extend-hooks/lib/gitlab/push_data_builder.rb#L52
4. https://gitlab.com/bugagazavr/gitlab-ce/blob/extend-hooks/lib/gitlab/note_data_builder.rb#L56

**Why was this MR needed?**

More information about user for push events, and more data about repositiry ( project )

**What are the relevant issue numbers?**

No

**Screenshots (if relevant)**

No

See merge request !2788
2016-02-16 13:08:36 +00:00
Douwe Maan 4ae2131376 Merge branch 'fix/13356-issuable-index-of-total-in-sidebar' into 'master'
Fix the "x of y" displayed at the top of Issuables' sidebar

1. We now display the index of the current issuable among all its project's
issuables, of the same type and with the same state.
1. Also, refactored a bit the Issuable helpers into a new `IssuablesHelper`
module.
1. Added acceptance specs for the sidebar counter.

Note: I didn't add a CHANGELOG item since it's a bug fix for an unreleased version.

Fixes #13356.

See merge request !2818
2016-02-16 13:02:33 +00:00
Rémy Coutable 1de9513790 Use project.web_url instead deprecated repository.homepage in PushoverService 2016-02-16 13:03:00 +01:00
Rémy Coutable d28fa2ce23 Display "iid of max_iid" in Issuables' sidebar 2016-02-16 12:58:12 +01:00
Douwe Maan b6c5d52ab5 Merge branch 'cleanup-repository-initialize' into 'master'
Cleaned up Repository#initialize

The "default_branch" argument is never used and the "project" argument
isn't optional.



See merge request !2832
2016-02-16 11:52:45 +00:00
Douwe Maan 21fa421ca3 Merge branch 'fix/13458-eager-load-blob-data' into 'master'
Eager-load image blob data in diffs

Since gitlab_git 8.0, blob data are lazy-loaded so we have to call
`blob.load_all_data!(repo)` to eager-load them.

Fixes #13458.

/cc @jacobvosmaer @dblessing @rspeicher 

### New image in commit view

#### Before
![Screen_Shot_2016-02-16_at_11.28.18](/uploads/01c2afa2d25f3249b27744154ab2069b/Screen_Shot_2016-02-16_at_11.28.18.png)

#### After
![Screen_Shot_2016-02-16_at_11.30.56](/uploads/5ef72f717f22dfd0c1efa9e6d8ed926f/Screen_Shot_2016-02-16_at_11.30.56.png)

### Replaced image in commit view

#### Before
![Screen_Shot_2016-02-16_at_11.28.20](/uploads/39bb61851608643a86d9d7616139fc6c/Screen_Shot_2016-02-16_at_11.28.20.png)

#### After
![Screen_Shot_2016-02-16_at_11.30.59](/uploads/27e754fe8b57a838ac695bace27618c3/Screen_Shot_2016-02-16_at_11.30.59.png)

### Deleted image in commit view

#### Before
![Screen_Shot_2016-02-16_at_11.28.22](/uploads/3648dcc2c36bc644556080e203a29fca/Screen_Shot_2016-02-16_at_11.28.22.png)

#### After
![Screen_Shot_2016-02-16_at_11.31.01](/uploads/2585915d994bb6e245dd8c8553730bbf/Screen_Shot_2016-02-16_at_11.31.01.png)

### Image diff in merge request diff view

#### Before
![Screen_Shot_2016-02-16_at_11.28.37](/uploads/a7963f7139fc91975ca40568570ce4f0/Screen_Shot_2016-02-16_at_11.28.37.png)

#### After
![Screen_Shot_2016-02-16_at_11.31.04](/uploads/6773dbf3b870f082f0262febc9722d20/Screen_Shot_2016-02-16_at_11.31.04.png)

See merge request !2830
2016-02-16 11:48:52 +00:00
Douwe Maan 42d088fcb1 Merge branch 'fix/cross-reference-notes-forks' into 'master'
Fix cross reference notes  on forks

Updates `cross_reference_exists?` to match on commit only.

Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/5849

See merge request !2731
2016-02-16 11:47:46 +00:00
Douwe Maan 8db62f2548 Merge branch 'rs-issue-13467' into 'master'
Ensure Commit#show responds 404 instead of 500 when given an invalid ID

Closes #13467

See merge request !2823
2016-02-16 11:40:06 +00:00
Douwe Maan 1563caf437 Merge branch 'rs-git_not_found' into 'master'
Properly render the `errors/git_not_found` page



See merge request !2824
2016-02-16 11:39:42 +00:00
Yorick Peterse f253f72529 Cleaned up Repository#initialize
The "default_branch" argument is never used and the "project" argument
isn't optional.
2016-02-16 12:13:13 +01:00
Rémy Coutable 5cd20de749 Eager-load image blob data in diffs
Since gitlab_git 8.0, blob data are lazy-loaded so we have to call
blob.load_all_data!(repo) to eager-load them.

Fixes #13458.
2016-02-16 10:50:24 +01:00
James Lopez 11913a762a updated system note service and spec based on feedback 2016-02-16 09:01:56 +01:00
Sytse Sijbrandij 3de6edd604 Updates to git flow documentation. 2016-02-15 19:38:36 -08:00
Robert Speicher ae13389b0b Provide explicit html format when rendering git_not_found page
Prior, if the request format was, for example, .zip, we'd get an
`ActionView::MissingTemplate` error.
2016-02-15 16:38:27 -05:00
Robert Speicher 012c75d1b0 Properly render the errors/git_not_found page 2016-02-15 15:52:39 -05:00
Robert Speicher f5ab126fd0 Ensure Commit#show responds 404 instead of 500 when given an invalid ID
Closes #13467
2016-02-15 15:48:16 -05:00
Robert Speicher c96b31b77a Merge branch 'rs-gitlab-database-module' into 'master'
Fix undefined method `postgresql?` during migration

See merge request !2820
2016-02-15 20:26:50 +00:00
Robert Speicher 447568d15f Fix undefined method postgresql? during migration 2016-02-15 14:13:47 -05:00
Rémy Coutable 54613b6af5 Fix the "x of y" displayed at the top of Issuables' sidebar
1. We now display the index of the current issuable among all its project's
issuables, of the same type and with the same state.
2. Also, refactored a bit the Issuable helpers into a new IssuablesHelper
module.
3. Added acceptance specs for the sidebar counter.
2016-02-15 15:40:24 +01:00
Douwe Maan c29517aaf4 Merge branch 'offline-migration-docs' into 'master'
Add notice about offline migrations

/cc @sytses 

See merge request !1723
2016-02-15 11:43:50 +00:00
Valery Sizov e654e68c3f Merge branch 'fix-me-me-me-me' into 'master'
Fix duplicate "me" in tooltip of the "thumbsup" awards Emoji

Steps to reproduce:

1. Go to a MR or issue
2. Click on "thumbsup" Emoji 3 times
3. Observe the tooltip becomes "me, me"

Closes #13374, #12788

See merge request !2804
2016-02-15 08:12:17 +00:00
Robert Speicher dc3ea7eb74 Merge branch 'update-omniauth-1-3-1' into 'master'
Update omniauth to 1.3.1 for memory performance

OmniAuth 1.3.1 may improve memory performance (~ 70% according to [intridea/omniauth!774](https://github.com/intridea/omniauth/pull/774)).

Closes #2404.

See merge request !2805
2016-02-13 18:45:16 +00:00
Douwe Maan 39b4e98631 Merge branch 'fix/ci-emails-broken-link' into 'master'
Fix broken link in CI build notification emails

Closes #13199

See merge request !2785
2016-02-13 17:17:40 +00:00
Douwe Maan ace8b0abbd Merge branch 'ben.boeckel/gitlab-ce-fixup-links-in-generic-docs' into 'master'
Fix relative links in other markup formats

_Originally opened at !1845 by @ben.boeckel._

- - -

The RelativeLinkFilter was not applied to other document formats, e.g.,
reStructuredText, so links from the Files view or the Project view did
not work.

Fixes #3533.

See merge request !2798
2016-02-13 17:04:27 +00:00
Stan Hu 46d35cdbe5 Add spinach tests for award emoji 2016-02-13 02:47:15 -08:00
Stan Hu 7ffcc5a17b Fix duplicate "me" in tooltip of the "thumbsup" awards Emoji
Steps to reproduce:

1. Go to a MR or issue
2. Click on "thumbsup" Emoji 3 times
3. Observe the tooltip becomes "me, me"

Closes #13374, #12788
2016-02-13 02:02:05 -08:00
Takuya Noguchi 4646cbc4c6 Update omniauth to 1.3.1 for memory performance 2016-02-13 12:59:55 +09:00
Achilleas Pipinellis 0f2dc6a7d7 Merge branch 'backup_ci_rm' into 'master'
Remove note on backing up GitLab CI as a separate service

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/13405

See merge request !2803
2016-02-12 22:39:33 +00:00
Achilleas Pipinellis 8a62fbdb42 Remove note on backing up GitLab CI as a separate service
[ci skip]
2016-02-13 00:37:43 +02:00
Douwe Maan 31c8dbc96f Merge branch 'fix-duplicate-hook-notifications' into 'master'
Fix duplicated branch creation/deletion Web hooks/service notifications when using Web UI

Similar to 423d2d6, except duplicates occurred only if a Web service (e.g. Slack) were
configured.

When deleting a branch, this is what was happening:

    1. DeleteBranchService calls execute_hooks and execute_services
    2. The call to repository.rm_branch triggers the GitHooksService.
    3. This, in turn, calls GitPushService and then calls the same hooks/services again.

5145706 now makes it no longer necessary for DeleteBranchService and CreateBranchService to execute
the branch hooks/services. Note that tags behave differently in GitTagPushService and GitPushService
is not called.

Closes #10330

See merge request !2763
2016-02-12 18:11:01 +00:00
Douwe Maan c142bde51d Merge branch 'fix_500-commit-null' into 'master'
Don't try to mark broken MR as mergable

In case merge request is broken, we shouldn't check if the sha
is mergable, as it will be null, and there's no point, as we know
that it's not mergable.

See merge request !2783
2016-02-12 17:40:40 +00:00
Douwe Maan 0174263c9b Merge branch 'rs-issue-merge-requests' into 'master'
Correct indentation for `issues/merge_requests` partial render

Prior, it would only be shown if the issue had been edited.

See merge request !2789
2016-02-12 17:30:43 +00:00
James Lopez 99a50447a1 fix rubocop warning 2016-02-12 18:21:01 +01:00
James Lopez 4089be8fed woo hoo - getting there with the cross-reference issue. Should fix the problem and updated spec 2016-02-12 18:01:47 +01:00
Ben BoeckelandRémy Coutable e919b5a4e9 Fix relative links in other markup formats
- Apply the RelativeLinkFilter filter to other formats, e.g.,
  reStructuredText so links from the Files view or the Project view work
- Remove the AsciidocPipeline pipeline

Fixes #3533.
2016-02-12 17:20:59 +01:00
Dmitriy Zaporozhets 0d866d89ec Merge branch 'rs-loosen-nokogiri' into 'master'
Loosen Nokogiri version requirement

Closes #13218

See merge request !2791
2016-02-12 13:13:18 +00:00
Grzegorz Bizon c0033e96ba Move profile notifications specs to separate file 2016-02-12 14:01:28 +01:00
Grzegorz Bizon 055ec4dc0a Move build emails specs to separate file
This also extracts shared examples for notification emails to separate
file.
2016-02-12 14:01:28 +01:00
Grzegorz Bizon 349adab142 Add Changelog entry for links fixes in build emails 2016-02-12 14:01:28 +01:00
Grzegorz Bizon c9f202b2ef Fix broken link in CI build notification emails
Closes #13199
2016-02-12 14:01:27 +01:00
James Lopez a5b011c9d8 Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce into fix/cross-reference-notes-forks 2016-02-12 12:21:04 +01:00
Rémy Coutable b1dda81454 Merge branch 'workhorse-0.6.4' into 'master'
Use gitlab-workhorse 0.6.4

This fixes a bug in 8.5.0.rc1 where downloading Git blobs through the API is broken.

See merge request !2794
2016-02-12 10:24:25 +00:00
Rémy Coutable b136f26408 Merge branch 're-add-update-configuration-files-in-latest-upgrade-guide' into 'master'
Re-add "Update configuration files" section in the 8.4 to 8.5 upgrade guide

Needed because of !2782.

See merge request !2796
2016-02-12 09:35:52 +00:00
Douwe Maan 9022070fac Merge branch 'olirogers/gitlab-ce-project-milestone-order' into 'master'
Fix milestone order in project and issue edit lists to due_date

_Originally opened at !2579 by @olirogers._

- - -

This MR orders the milestones by due date (earliest first) in the project and edit issue view. These suggestions were made be @orih in #6001 and fixes #6001.

This continues the work of !1934 to order milestones.

I found this annoying when creating milestones, found #6001 but no attached MR. This is my first for this project - comments and criticisms welcome.

See merge request !2780
2016-02-12 09:32:57 +00:00
Rémy Coutable 41d24868e9 Re-add "Update configuration files" section in the 8.4 to 8.5 upgrade guide
Needed because of !2782.

[ci skip]
2016-02-12 10:32:47 +01:00
Achilleas Pipinellis e45bc034fa Merge branch 'typo_api_builds_doc' into 'master'
Fix typo in doc/api/builds.md



See merge request !2795
2016-02-12 09:27:16 +00:00
Achilleas Pipinellis 324e6743cf Fix typo in doc/api/builds.md
[ci skip]
2016-02-12 11:25:20 +02:00
Douwe Maan 2afd95a025 Merge branch 'streamline-email-validation' into 'master'
Validate email addresses using Devise.email_regexp

Also:
- Get rid of legacy `:strict_mode`
- Get rid of custom `:email` validator
- Add some shared examples to spec emails validation

This supersedes !2754 and fixes #3851.

See merge request !2771
2016-02-12 09:09:23 +00:00