diff --git a/CHANGELOG b/CHANGELOG index 5f69fb902e..6ceb9509bc 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -53,12 +53,15 @@ v 7.9.0 (unreleased) - Starred projects page at dashboard - Make email display name configurable - Improve json validation in hook data + - Use Emoji One + v 7.8.4 - Fix issue_tracker_id substitution in custom issue trackers - Fix path and name duplication in namespaces v 7.8.3 - Bump version of gitlab_git fixing annotated tags without message + - Allow smb:// links in Markdown text. v 7.8.2 - Fix service migration issue when upgrading from versions prior to 7.3 diff --git a/Gemfile b/Gemfile index 9eb196e07f..61316ee730 100644 --- a/Gemfile +++ b/Gemfile @@ -89,7 +89,7 @@ gem "six" gem "seed-fu" # Markup pipeline for GitLab -gem 'html-pipeline-gitlab', '~> 0.1.0' +gem 'html-pipeline-gitlab', '~> 0.1' # Markdown to HTML gem "github-markup" @@ -196,7 +196,7 @@ gem "jquery-scrollto-rails" gem "raphael-rails", "~> 2.1.2" gem 'bootstrap-sass', '~> 3.0' gem "font-awesome-rails", '~> 4.2' -gem "gitlab_emoji", "~> 0.0.1.1" +gem "gitlab_emoji", "~> 0.1" gem "gon", '~> 5.0.0' gem 'nprogress-rails' gem 'request_store' diff --git a/Gemfile.lock b/Gemfile.lock index 89ef83b01a..70f239c666 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -144,8 +144,6 @@ GEM email_spec (1.5.0) launchy (~> 2.1) mail (~> 2.2) - emoji (1.0.1) - json enumerize (0.7.0) activesupport (>= 3.2) equalizer (0.0.8) @@ -193,6 +191,8 @@ GEM formatador (0.2.4) gemnasium-gitlab-service (0.2.4) rugged (~> 0.21) + gemojione (2.0.0) + json gherkin-ruby (0.3.1) racc github-markup (1.3.1) @@ -211,8 +211,8 @@ GEM charlock_holmes (~> 0.6.6) escape_utils (~> 0.2.4) mime-types (~> 1.19) - gitlab_emoji (0.0.1.1) - emoji (~> 1.0.1) + gitlab_emoji (0.1.0) + gemojione (~> 2.0) gitlab_git (7.1.0) activesupport (~> 4.0) charlock_holmes (~> 0.6) @@ -278,10 +278,11 @@ GEM html-pipeline (1.11.0) activesupport (>= 2) nokogiri (~> 1.4) - html-pipeline-gitlab (0.1.5) + html-pipeline-gitlab (0.2.0) actionpack (~> 4) - gitlab_emoji (~> 0.0.1) + gitlab_emoji (~> 0.1) html-pipeline (~> 1.11.0) + mime-types sanitize (~> 2.1) http_parser.rb (0.5.3) httparty (0.13.0) @@ -712,7 +713,7 @@ DEPENDENCIES gitlab-flowdock-git-hook (~> 0.4.2) gitlab-grack (~> 2.0.0.rc2) gitlab-linguist (~> 3.0.1) - gitlab_emoji (~> 0.0.1.1) + gitlab_emoji (~> 0.1) gitlab_git (= 7.1.0) gitlab_meta (= 7.0) gitlab_omniauth-ldap (= 1.2.0) @@ -725,7 +726,7 @@ DEPENDENCIES guard-spinach haml-rails hipchat (~> 1.4.0) - html-pipeline-gitlab (~> 0.1.0) + html-pipeline-gitlab (~> 0.1) httparty jasmine (= 2.0.2) jquery-atwho-rails (~> 0.3.3) diff --git a/app/assets/stylesheets/generic/nav_sidebar.scss b/app/assets/stylesheets/generic/nav_sidebar.scss index 4bf2c609be..c14f12284d 100644 --- a/app/assets/stylesheets/generic/nav_sidebar.scss +++ b/app/assets/stylesheets/generic/nav_sidebar.scss @@ -147,7 +147,7 @@ .collapse-nav a { left: 0px; - padding: 5px 23px 3px 22px; + padding: 7px 23px 3px 22px; } } } @@ -155,12 +155,19 @@ .collapse-nav a { position: fixed; top: 46px; - padding: 5px 13px 3px 13px; + padding: 5px 13px 5px 13px; left: 197px; font-size: 13px; background: #EEE; color: black; - border: 1px solid rgba(0,0,0,0.035); + border-left: 1px solid rgba(0,0,0,0.035); + border-right: 1px solid rgba(0,0,0,0.035); +} + +.collapse-nav a:hover { + text-decoration: none; + color: #333; + background: #eaeaea; } @media (max-width: $screen-md-max) { diff --git a/app/controllers/groups/application_controller.rb b/app/controllers/groups/application_controller.rb new file mode 100644 index 0000000000..7f27f2bb73 --- /dev/null +++ b/app/controllers/groups/application_controller.rb @@ -0,0 +1,10 @@ +class Groups::ApplicationController < ApplicationController + + private + + def authorize_admin_group! + unless can?(current_user, :manage_group, group) + return render_404 + end + end +end diff --git a/app/controllers/groups/group_members_controller.rb b/app/controllers/groups/group_members_controller.rb index 114acca51e..613a8ee0a4 100644 --- a/app/controllers/groups/group_members_controller.rb +++ b/app/controllers/groups/group_members_controller.rb @@ -1,4 +1,4 @@ -class Groups::GroupMembersController < ApplicationController +class Groups::GroupMembersController < Groups::ApplicationController before_filter :group # Authorize @@ -75,12 +75,6 @@ class Groups::GroupMembersController < ApplicationController @group ||= Group.find_by(path: params[:group_id]) end - def authorize_admin_group! - unless can?(current_user, :manage_group, group) - return render_404 - end - end - def member_params params.require(:group_member).permit(:access_level, :user_id) end diff --git a/app/controllers/groups_controller.rb b/app/controllers/groups_controller.rb index 6965035c37..c36ac2c712 100644 --- a/app/controllers/groups_controller.rb +++ b/app/controllers/groups_controller.rb @@ -1,4 +1,4 @@ -class GroupsController < ApplicationController +class GroupsController < Groups::ApplicationController skip_before_filter :authenticate_user!, only: [:show, :issues, :members, :merge_requests] respond_to :html before_filter :group, except: [:new, :create] @@ -134,12 +134,6 @@ class GroupsController < ApplicationController end end - def authorize_admin_group! - unless can?(current_user, :manage_group, group) - return render_404 - end - end - def set_title @title = 'New Group' end diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 9b1c33d6c7..bd6c99ca0f 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -177,11 +177,11 @@ class ProjectsController < ApplicationController end def autocomplete_emojis - Rails.cache.fetch("autocomplete-emoji-#{Emoji::VERSION}") do - Emoji.names.map do |e| + Rails.cache.fetch("autocomplete-emoji-#{Gemojione::VERSION}") do + Emoji.emojis.map do |name, emoji| { - name: e, - path: view_context.image_url("emoji/#{e}.png") + name: name, + path: view_context.image_url("emoji/#{emoji["unicode"]}.png") } end end diff --git a/app/helpers/gitlab_markdown_helper.rb b/app/helpers/gitlab_markdown_helper.rb index daaefe90f1..f8e104b082 100644 --- a/app/helpers/gitlab_markdown_helper.rb +++ b/app/helpers/gitlab_markdown_helper.rb @@ -121,7 +121,7 @@ module GitlabMarkdownHelper end def ignored_protocols - ["http://","https://", "ftp://", "mailto:"] + ["http://","https://", "ftp://", "mailto:", "smb://"] end def rebuild_path(file_path) diff --git a/config/application.rb b/config/application.rb index bd4578848c..fa399533e5 100644 --- a/config/application.rb +++ b/config/application.rb @@ -50,6 +50,8 @@ module Gitlab # Version of your assets, change this if you want to expire all your assets config.assets.version = '1.0' + config.action_view.sanitized_allowed_protocols = %w(smb) + # Relative url support # Uncomment and customize the last line to run in a non-root path # WARNING: We recommend creating a FQDN to host GitLab in a root path instead of this. diff --git a/doc/release/monthly.md b/doc/release/monthly.md index a7e5faf2a6..ec96be27f3 100644 --- a/doc/release/monthly.md +++ b/doc/release/monthly.md @@ -51,6 +51,7 @@ Xth: (5 working days before the 22nd) Xth: (4 working days before the 22nd) - [ ] Update GitLab.com with rc1 (#LINK) (https://dev.gitlab.org/cookbooks/chef-repo/blob/master/doc/administration.md#deploy-the-package) +- [ ] Update ci.gitLab.com with rc1 (#LINK) (https://dev.gitlab.org/cookbooks/chef-repo/blob/master/doc/administration.md#deploy-the-package) - [ ] Create regression issues (CE, CI) (#LINK) - [ ] Tweet about rc1 (#LINK) @@ -68,6 +69,7 @@ Xth: (1 working day before the 22nd) - [ ] Create CE, EE, CI stable versions (#LINK) - [ ] Create Omnibus tags and build packages - [ ] Update GitLab.com with the stable version (#LINK) +- [ ] Update ci.gitLab.com with the stable version (#LINK) 22nd: diff --git a/doc/release/patch.md b/doc/release/patch.md index 5397343e71..68156ae9c0 100644 --- a/doc/release/patch.md +++ b/doc/release/patch.md @@ -51,6 +51,7 @@ CE=false be rake release['x.x.x'] 1. [Build new packages with the latest version](https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/release.md) 1. Apply the patch to GitLab.com and the private GitLab development server +1. Apply the patch to ci.gitLab.com and the private GitLab CI development server 1. Create and publish a blog post, see [patch release blog template](https://gitlab.com/gitlab-com/www-gitlab-com/blob/master/doc/patch_release_blog_template.md) 1. Send tweets about the release from `@gitlab`, tweet should include the most important feature that the release is addressing and link to the blog post 1. Note in the 'GitLab X.X regressions' issue that the patch was published (CE only) diff --git a/doc/release/security.md b/doc/release/security.md index 6ed2526449..60bcfbb6da 100644 --- a/doc/release/security.md +++ b/doc/release/security.md @@ -18,6 +18,7 @@ Please report suspected security vulnerabilities in private to