Commit Graph
10567 Commits
Author SHA1 Message Date
Grzegorz Bizon e2f937ce22 Refactor RepositoryPush, move to Message namespace 2015-12-08 08:43:08 +01:00
Grzegorz Bizon 45f7f01f19 Make can_send_from_user_email? public in Notify 2015-12-08 08:43:08 +01:00
Grzegorz Bizon 8c6db54e12 Extract repository_push_email to separate class 2015-12-08 08:43:08 +01:00
Dmitriy Zaporozhets bdb4945dcf Fix random failing test - delete attachment
Make sure we wait for AJAX request to finish before end test and cleanup
database

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-12-07 23:40:17 +01:00
Robert Speicher 9d03bc6fa3 Merge branch 'pberndt:master' into 'master'
Fix #3758: Serious performance issues due to timeago()
being called n*(n+1)/2 times instead of n

See bug #3758 for a description. This merge request alters 
`time_ago_with_tooltip` to invoke the `timeago()` javascript on the
current timestamp only, instead of each one defined on the page so far.

See merge request !1977
2015-12-07 20:01:39 +00:00
Dmitriy Zaporozhets 2e074500b2 Merge branch 'fix-parallel-merge' into 'master'
Dont use cached collection for Repository find_branch and find_tag methods

Fix for #3816 

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

See merge request !2003
2015-12-07 19:53:30 +00:00
Dmitriy Zaporozhets 949a7e8e20 Merge branch 'report-ssl-errors' of https://gitlab.com/stanhu/gitlab-ce 2015-12-07 20:17:29 +01:00
Dmitriy Zaporozhets 1da71fa9ed Merge branch 'feature/sidekiq-cron' into 'master'
Migrate from Sidetiq to Sidekiq-cron

Migrate from Sidetiq to Sidekiq-cron
Updated Sidekiq to 3.5.x

This will solve #2355

See merge request !1982
2015-12-07 18:53:59 +00:00
Dmitriy Zaporozhets 2cec90254f Dont use cached collection for Repository find_branch and find_tag methods
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-12-07 19:37:05 +01:00
Valery Sizov bd5fb1b479 Merge branch 'webhook_payload_with_changes' into 'master'
Add added, modified and removed properties to commit object in webhook

https://gitlab.com/gitlab-org/gitlab-ee/issues/20

See merge request !1988
2015-12-07 14:43:13 +00:00
Valery Sizov 3c97cbc74c fixes after review 2015-12-07 15:13:06 +02:00
Douwe Maan a468bf346a Merge branch 'gsmethells/gitlab-ce-sort-by-due-date' 2015-12-07 13:45:16 +01:00
Douwe Maan ff08ce9ca4 Satisfy Rubocop 2015-12-07 13:45:00 +01:00
Grzegorz Bizon 359d94607c Merge branch 'fix/award-emoji-conflict-in-notes' into 'master'
Fix problems with award-emoji-only comment

This fixes a conflict between note with only a single emoji in content
and award-emojis mechanisms.

Closes #3734 

cc @vsizov

See merge request !1936
2015-12-07 12:26:56 +00:00
Valery Sizov 5df2c4419c fox specs 2015-12-07 14:14:35 +02:00
Douwe Maan 104df74f51 Merge branch 'fix-global-milestones-error-500' into 'master'
Fix Error 500 when creating global milestones with Unicode characters

Two issues:

1. The constraints in the resources were incorrect. Here's what it was before:

```
group_milestone  GET /groups/:group_id/milestones/:id(.:format)  groups/milestones#show {:id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/, :group_id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/}
```

In this case, id is actually the title of the milestone, which can be anything at the moment.

After:
```
group_milestone  GET /groups/:group_id/milestones/:id(.:format)  groups/milestones#show {:id=>/[^\/]+/, :group_id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/}
```

2. `parameterize` would strip all Unicode characters, leaving a blank string. Rails would report something like:

```
ActionView::Template::Error (No route matches {:action=>"show", :controller=>"groups/milestones", :group_id=>#<Group id: 48, name: "ops-dev", path: "ops-dev", owner_id: nil, created_at: "2015-11-15 08:55:30", updated_at: "2015-12-02 06:23:26", type: "Group", description: "", avatar: "sha1.c71e73d51af1865c1bbbf6208e10044d46c9bb93.png", public: false>, :id=>"", :title=>"肯定不是中文的问题"} missing required keys: [:id]):
```

This change uses the babosa library to create a better slug, which surprisingly
isn't actually used by the global milestone controllers. Instead, they use the
title passed as a query string for some reason.

Closes https://github.com/gitlabhq/gitlabhq/issues/9881

See merge request !1983
2015-12-07 11:45:10 +00:00
Douwe Maan 4c353143d6 Merge branch 'style-warning-about-mentioning-many-people-in-a-comment' into 'master'
Style warning about mentioning many people in a comment

Fixes #2885 

* Create issue:

    Before:

    ![Screenshot_2015-12-03_15.23.44](/uploads/6da9b326e47dc5e8c127a581af99403c/Screenshot_2015-12-03_15.23.44.png)

    After:

    ![Screenshot_2015-12-03_15.21.29](/uploads/bbe328d30a32d642c280bf2ad6d2832c/Screenshot_2015-12-03_15.21.29.png)  
    &nbsp; 

* New merge request:

    Before:

    ![Screenshot_2015-12-03_15.24.06](/uploads/79d6f8f52ba2753aaecf6b6bbd04f0d0/Screenshot_2015-12-03_15.24.06.png)

    After:

    ![Screenshot_2015-12-03_15.21.48](/uploads/f01ea8e7d058a9f8b803ca1ce4f533ad/Screenshot_2015-12-03_15.21.48.png)
    &nbsp;

* New comment in a merge request:

    Before:

    ![Screenshot_2015-12-03_15.11.23](/uploads/5d958375812d21d41e00694186c7ef7a/Screenshot_2015-12-03_15.11.23.png)

    After:

    ![Screenshot_2015-12-03_15.09.08](/uploads/3d6bde6aad46c7d9e53b70a47eecf7c0/Screenshot_2015-12-03_15.09.08.png)
    &nbsp;

* New diff comment:

    Before:

    ![Screenshot_2015-12-03_15.25.50](/uploads/08ac9c261c1aa9693706da714c121e15/Screenshot_2015-12-03_15.25.50.png)

    After:

    ![Screenshot_2015-12-03_15.46.20](/uploads/07a8b8708ad825eb8cda7e5e40116b81/Screenshot_2015-12-03_15.46.20.png)

See merge request !1971
2015-12-07 11:09:13 +00:00
Douwe Maan 6368717852 Merge branch 'issue_1156' 2015-12-07 12:07:22 +01:00
Douwe Maan 0bca65b283 Merge branch 'master' into gsmethells/gitlab-ce-sort-by-due-date 2015-12-07 12:03:34 +01:00
Grzegorz Bizon 893d08c0dc Simplify contains_emoji_only? method in Note 2015-12-07 11:00:03 +01:00
Anton Baklanov caa6851bf5 Fixed duplicated issue note email notifications.
Fixes #2560
2015-12-06 01:20:42 +02:00
Grzegorz Bizon bfe91b692a Remove space before exclamation mark in award alert
[ci skip]
2015-12-05 22:18:13 +01:00
Grzegorz Bizon 176d6e2a8f Refactor note awards to reuse emoji_pattern and improve validator 2015-12-05 22:09:52 +01:00
Andrew Tomaka 1c53dc28b5 Notify user if they cannot create projects 2015-12-05 11:32:08 -05:00
Stan Hu d800a949d2 Fix Error 500 when creating global milestones with Unicode characters
Two issues:

1. The constraints in the resources were incorrect. Here's what it was before:
```
group_milestone  GET /groups/:group_id/milestones/:id(.:format)  groups/milestones#show {:id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/, :group_id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/}
```

In this case, id is actually the title of the milestone, which can be anything at the moment.

After:

```
group_milestone  GET /groups/:group_id/milestones/:id(.:format)  groups/milestones#show {:id=>/[^\/]+/, :group_id=>/[a-zA-Z.0-9_\-]+(?<!\.atom)/}
```

2. `parameterize` would strip all Unicode characters, leaving a blank string. Rails would report something like:

ActionView::Template::Error (No route matches {:action=>"show", :controller=>"groups/milestones", :group_id=>#<Group id: 48, name: "ops-dev", path: "ops-dev", owner_id: nil, created_at: "2015-11-15 08:55:30", updated_at: "2015-12-02 06:23:26", type: "Group", description: "", avatar: "sha1.c71e73d51af1865c1bbbf6208e10044d46c9bb93.png", public: false>, :id=>"", :title=>"肯定不是中文的问题"} missing required keys: [:id]):

This change uses the babosa library to create a better slug, which surprisingly
isn't actually used by the global milestone controllers. Instead, they use the
title passed as a query string for some reason.

Closes https://github.com/gitlabhq/gitlabhq/issues/9881

Fix constraints
2015-12-05 00:04:44 -08:00
Robert Speicher d2f9a9012d Merge branch 'link-refs' into 'master'
Recognize issue/MR/snippet/commit links as references.

Fixes #3744 and #3745

See merge request !1933
2015-12-04 20:58:45 +00:00
Douglas Barbosa Alexandre 29e5506799 Merge branch 'master' into style-warning-about-mentioning-many-people-in-a-comment 2015-12-04 18:11:49 -02:00
Dmitriy Zaporozhets e7e22ece5a Merge branch 'issue_3583' into 'master'
Ensure "Remove Source Branch" button is not shown when branch is being deleted.

Given the merging of the Merge Request happens in the background, sometimes when the client JS code reloads the page the source branch is not still gone.

This fix appends a new query string parameter that is checked in the view before rendering the `Remove Source Branch` button.

Closes #3583

See merge request !1897
2015-12-04 17:01:03 +00:00
Dmitriy Zaporozhets 40143a8eee Merge branch 'fix-application-settings-not-expiring' into 'master'
Fix application settings cache not expiring after changes

cache_key is an instance method that relies on updated_at. When changes
were made, the time-dependent key was being used instead of X.application_setting.last.

Closes #3609 


See merge request !1972
2015-12-04 16:54:50 +00:00
Rubén Dávila aa1ba00936 Ensure "Remove Source Branch" button is not shown when branch is being deleted. #3583 2015-12-04 10:43:33 -05:00
Stan Hu 253301bb47 Make current user the first user in assignee dropdown in issues detail page
Closes #3679
2015-12-04 07:14:04 -08:00
Stan Hu a120b78940 Handle and report SSL errors in Web hook test. Check for status 200 for success.
If a Web hook test fails due to an SSL error or some other error, report
the result back to the user instead of an Error 500.

Closes #3656

Handle response
2015-12-04 07:13:28 -08:00
Stan Hu 32b45493b8 Fix application settings cache not expiring after changes
cache_key is an instance method that relies on updated_at. When changes
were made, the time-dependent key was being used instead of X.application_setting.last.

Closes #3609
2015-12-04 07:11:25 -08:00
Valery Sizov 5c1b49f494 Add added, modified and removed properties to commit object in webhook 2015-12-04 16:23:21 +02:00
Dmitriy Zaporozhets 238ca3e472 Merge remote-tracking branch 'origin/ui/issuable-form'
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-12-04 15:12:03 +01:00
Gabriel Mazetto 496870ddec Migrate from Sidetiq to Sidekiq-cron
Updated Sidekiq to 3.5.x
2015-12-04 11:29:45 -02:00
Dmitriy Zaporozhets abf54f230e Merge branch 'ui/sidebar' into 'master'
UI: Sidebar & header tweaks and fixes

Depends on !1953 

See the commits for more details, the messages mostly speak for themselves.

![Logo](https://gitlab.com/gitlab-org/gitlab-ce/uploads/ba088150165bb0a0aea1e894f3443f43/logo_tooltip.png)

![Sidebar](https://gitlab.com/gitlab-org/gitlab-ce/uploads/c1e8c09ac3bf489cdb9531eebea18c90/sidebar_tooltips.png)

Fixes #2928, #2071, https://dev.gitlab.org/gitlab/gitlabhq/issues/2575, and https://dev.gitlab.org/gitlab/gitlabhq/issues/2573

See merge request !1958
2015-12-04 09:31:28 +00:00
Dmitriy Zaporozhets eb9601d906 Merge branch 'ui/form-consistency' into 'master'
UI: Improve form consistency

Depends on !1953

See the commits for more details, the messages mostly speak for themselves.

# Highlights

## Tag form

Before:

![tag_before](/uploads/ee5ba6ef405749013f9e5717ebcf72f3/tag_before.png)

After:

![tag_after](/uploads/71bb543553190d91c03fd706cce35923/tag_after.png)


See merge request !1955
2015-12-04 09:27:27 +00:00
Dmitriy Zaporozhets de3a175486 Merge branch 'ui/login-page' into 'master'
Fix background and padding of login and error pages

Was gray, is white again.

See merge request !1978
2015-12-04 09:24:42 +00:00
Robert Speicher e9d06903da Merge branch 'fork-event' into 'master'
Don't show project fork event as imported

See merge request !1949
2015-12-03 23:52:34 +00:00
Robert Speicher 05d5485dd4 Merge branch 'new-tag-branch-authorization' into 'master'
Add authorization to new branch/tag pages.

The create actions have authorization, the new actions didn't,
so no-one unauthorized could actually do anything, but it was wrong(TM).

See merge request !1979
2015-12-03 23:46:55 +00:00
Douglas Barbosa Alexandre 0decc7f941 Fix specs 2015-12-03 19:46:30 -02:00
Drew Blessing 1481255efa Merge branch 'issue_3468_broken_link' into 'master'
Fixed invalid link on starred projects dashboard.

Fixes #3468

The MR fixes 'Project' links on a dashboard pages headers. See the issue for the details.

This MR does not include tests since the change is rather trivial and there are no (as far as I have seen) existing tests for checking links validity.

In case tests are required I would like to get some guidance on the implementation first. At least I would like to know what should be covered: changed links, all header links, all navigation?

See merge request !1926
2015-12-03 21:13:00 +00:00
Dmitriy Zaporozhets abb7261889 Merge branch 'ui/wiki' into 'master'
UI: Use new style for wiki

Depends on !1953

See the commits for more details, the messages mostly speak for themselves.

# Highlights

## Wiki Page

Before:

![Screen_Shot_2015-12-02_at_17.48.45](/uploads/aa53f768b8760f2e15d765e06d5ff773/Screen_Shot_2015-12-02_at_17.48.45.png)

After:

![Screen_Shot_2015-12-02_at_17.48.16](/uploads/f8a376651aff9c8de82621578aaeb002/Screen_Shot_2015-12-02_at_17.48.16.png)

## Edit Wiki Page

Before:

![Screen_Shot_2015-12-02_at_17.48.59](/uploads/c9ffddaca3156046b99cba11bdb0ea4f/Screen_Shot_2015-12-02_at_17.48.59.png)

After:

![Screen_Shot_2015-12-02_at_17.48.26](/uploads/1aa62049f120c91436ed68fd7441c156/Screen_Shot_2015-12-02_at_17.48.26.png)

See merge request !1967
2015-12-03 20:17:48 +00:00
Dmitriy Zaporozhets e7452c6b8f Merge branch 'ui/new-project' into 'master'
UI: New Project form tweaks

Depends on !1953 

See the commits for more details, the messages mostly speak for themselves.

Before:

![Screen_Shot_2015-12-02_at_17.43.23](/uploads/302e734f6796a85a9f4be9c2f494869d/Screen_Shot_2015-12-02_at_17.43.23.png)

After:

![Screen_Shot_2015-12-02_at_17.44.11](/uploads/411980e53a4f87cf0a04e5bcb7329f82/Screen_Shot_2015-12-02_at_17.44.11.png)


See merge request !1964
2015-12-03 19:46:47 +00:00
Dmitriy Zaporozhets 805b4cf522 Merge branch 'ui/issuable-filter' into 'master'
UI: Issuable filter tweaks

Depends on !1953

See the commits for more details, the messages mostly speak for themselves.

# Highlights

## Filter bar

Before:

![filter_before](/uploads/b061be7521c6d5babb77c7d12e77f65e/filter_before.png)

After:

![filter_after](/uploads/aadfbcd77caf1b49fde8ca6d781f1004/filter_after.png)

## Bulk edit bar

Before:

![bulk_before](/uploads/849c98224e1f335c65c0de5616bbcdae/bulk_before.png)

After:

![bulk_after](/uploads/185d29116663f9f663acab76d328096f/bulk_after.png)


See merge request !1963
2015-12-03 19:43:41 +00:00
Anton Baklanov c5b6b31c84 Fixed invalid link on starred projects dashboard.
Fixes #3468
2015-12-03 21:06:15 +02:00
Douwe Maan e5c865eebf Fix specs 2015-12-03 20:01:35 +01:00
Gabriel Mazetto 82e916b0f2 Touch project when toggling stars to update cache 2015-12-03 16:08:08 -02:00
Douglas Barbosa Alexandre 510f3bf70b Merge branch 'master' into style-warning-about-mentioning-many-people-in-a-comment 2015-12-03 16:00:05 -02:00