From 5582ae145d3b27b8e1713f966dff62fc3ba2307b Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 13:24:10 +0200 Subject: [PATCH 01/12] Fix project transfer feature Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> --- app/views/projects/edit.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/projects/edit.html.haml b/app/views/projects/edit.html.haml index c56919e792c..44f722d9e15 100644 --- a/app/views/projects/edit.html.haml +++ b/app/views/projects/edit.html.haml @@ -130,7 +130,7 @@ .title Transfer project .errors-holder .form-holder - = form_for(@project, url: transfer_project_path(@project), remote: true, html: { class: 'transfer-project' }) do |f| + = form_for(@project, url: transfer_project_path(@project), method: :put, remote: true, html: { class: 'transfer-project' }) do |f| .control-group = f.label :namespace_id do %span Namespace -- GitLab From cc51931d1f4a205de412ed8dfca98b832f4c5c91 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 13:19:13 +0200 Subject: [PATCH 02/12] Fix 500 error when rename repository Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> --- app/contexts/projects/update_context.rb | 2 +- features/project/project.feature | 5 +++++ features/steps/project/project.rb | 15 ++++++++++++--- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/app/contexts/projects/update_context.rb b/app/contexts/projects/update_context.rb index ed0d451a31a..94de10de0f6 100644 --- a/app/contexts/projects/update_context.rb +++ b/app/contexts/projects/update_context.rb @@ -9,7 +9,7 @@ module Projects new_branch = params[:project].delete(:default_branch) - if project.repository.exists? && new_branch != project.default_branch + if project.repository.exists? && new_branch && new_branch != project.default_branch project.change_head(new_branch) end diff --git a/features/project/project.feature b/features/project/project.feature index 59eda4a781d..d8bb1d55e2d 100644 --- a/features/project/project.feature +++ b/features/project/project.feature @@ -19,3 +19,8 @@ Feature: Project Feature And change project settings And I save project Then I should see project with new settings + + Scenario: I change project path + When I visit edit project "Shop" page + And change project path settings + Then I should see project with new path settings diff --git a/features/steps/project/project.rb b/features/steps/project/project.rb index a96b086fae5..92728d474b2 100644 --- a/features/steps/project/project.rb +++ b/features/steps/project/project.rb @@ -3,16 +3,25 @@ class ProjectFeature < Spinach::FeatureSteps include SharedProject include SharedPaths - And 'change project settings' do + step 'change project settings' do fill_in 'project_name', with: 'NewName' uncheck 'project_issues_enabled' end - And 'I save project' do + step 'I save project' do click_button 'Save changes' end - Then 'I should see project with new settings' do + step 'I should see project with new settings' do find_field('project_name').value.should == 'NewName' end + + step 'change project path settings' do + fill_in "project_path", with: "new-path" + click_button "Rename" + end + + step 'I should see project with new path settings' do + project.path.should == "new-path" + end end -- GitLab From 6bc3b5dfa12ef28c2f11ebe003e45b2a051ae2b5 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 14:21:40 +0200 Subject: [PATCH 03/12] Version to 6.4.1 Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 19b860c1872..4c77920fd2c 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -6.4.0 +6.4.1 -- GitLab From 58472180b358dc893e2361908a7965d1e9185ddc Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 18:01:51 +0200 Subject: [PATCH 04/12] Fix upgrader It created branch based on current branch which is an old version Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> --- lib/gitlab/upgrader.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/gitlab/upgrader.rb b/lib/gitlab/upgrader.rb index 1de681a97ff..859923cb563 100644 --- a/lib/gitlab/upgrader.rb +++ b/lib/gitlab/upgrader.rb @@ -51,7 +51,7 @@ module Gitlab { "Stash changed files" => "git stash", "Get latest code" => "git fetch", - "Switch to new version" => "git checkout -b v#{latest_version}", + "Switch to new version" => "git checkout v#{latest_version}", "Install gems" => "bundle", "Migrate DB" => "bundle exec rake db:migrate RAILS_ENV=production", "Recompile assets" => "bundle exec rake assets:clean assets:precompile RAILS_ENV=production", -- GitLab From 214a013bb2395883ae04e819ca703f839b1f63c4 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 18:11:40 +0200 Subject: [PATCH 05/12] Version to 6.4.2 Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 4c77920fd2c..a4c853ea2ea 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -6.4.1 +6.4.2 -- GitLab From 221af222d685dfcd34c99b1f5d757a04ce1409e2 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 18:29:10 +0200 Subject: [PATCH 06/12] Add 6.4.1 and 6.4.2 CHANGELOG Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Conflicts: CHANGELOG --- CHANGELOG | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index d3119846760..acbee9c067b 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,10 @@ +v6.4.2 + - Fixed wrong behaviour of script/upgrade.rb + +v6.4.1 + - Fixed bug with repository rename + - Fixed bug with project transfer + v 6.4.0 - Added sorting to project issues page (Jason Blanchard) - Assembla integration (Carlos Paramio) -- GitLab From 84093385d6f70946dae0772a0913e19ab6a16db0 Mon Sep 17 00:00:00 2001 From: James Newton <james@Zaphyous.com> Date: Fri, 20 Dec 2013 10:30:34 -0600 Subject: [PATCH 07/12] don't use unicorn worker killer if PhusionPassenger is defined --- config.ru | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/config.ru b/config.ru index 1edcd391e45..f7e5e091534 100644 --- a/config.ru +++ b/config.ru @@ -1,10 +1,12 @@ # This file is used by Rack-based servers to start the application. -# Unicorn self-process killer -require 'unicorn/worker_killer' +unless defined?(PhusionPassenger) + # Unicorn self-process killer + require 'unicorn/worker_killer' -# # Max memory size (RSS) per worker -use Unicorn::WorkerKiller::Oom, (200 * (1 << 20)), (250 * (1 << 20)) + # Max memory size (RSS) per worker + use Unicorn::WorkerKiller::Oom, (200 * (1 << 20)), (250 * (1 << 20)) +end require ::File.expand_path('../config/environment', __FILE__) -- GitLab From 42131d0189bbc0e88be72e6a76405140cbd79fc8 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Date: Mon, 23 Dec 2013 20:43:59 +0200 Subject: [PATCH 08/12] Version to 6.4.3 Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index a4c853ea2ea..133cad286fd 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -6.4.2 +6.4.3 -- GitLab From eae84c0c37878675f6068190b14e428d6ee9b0b4 Mon Sep 17 00:00:00 2001 From: Manly Florido <manly.florido@gmail.com> Date: Mon, 30 Dec 2013 15:24:47 +0800 Subject: [PATCH 09/12] Update Gemfile --- Gemfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index 2019cae8f96..d34603e8ce1 100644 --- a/Gemfile +++ b/Gemfile @@ -154,7 +154,7 @@ gem "raphael-rails", "~> 2.1.2" gem 'bootstrap-sass', '~> 2.3' gem "font-awesome-rails", '~> 3.2' gem "gemoji", "~> 1.3.0" -gem "gon", git: "https://github.com/gitlabhq/gon.git", ref: '58ca8e17273051cb370182cabd3602d1da6783ab' +gem "gon", "~> 5.0.0" group :development do gem "annotate", "~> 2.6.0.beta2" -- GitLab From 5b2ac3fa26cb2c7ba92f76537133f6334b8bc47c Mon Sep 17 00:00:00 2001 From: Manly Florido <manly.florido@gmail.com> Date: Mon, 30 Dec 2013 15:33:15 +0800 Subject: [PATCH 10/12] Update Gemfile.lock --- Gemfile.lock | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 8aad7c8c424..29eb52a5bd7 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,12 +1,3 @@ -GIT - remote: https://github.com/gitlabhq/gon.git - revision: 58ca8e17273051cb370182cabd3602d1da6783ab - ref: 58ca8e17273051cb370182cabd3602d1da6783ab - specs: - gon (4.1.1) - actionpack (>= 2.3.0) - json - GEM remote: https://rubygems.org/ specs: @@ -206,6 +197,9 @@ GEM omniauth (~> 1.0) pyu-ruby-sasl (~> 0.0.3.1) rubyntlm (~> 0.1.1) + gon (5.0.0) + actionpack (>= 2.3.0) + json grape (0.6.1) activesupport builder -- GitLab From db5b70b1c567b1405310b699e894e3627737bc6a Mon Sep 17 00:00:00 2001 From: Yasuharu Ozaki <yasuharu.ozaki@gmail.com> Date: Sun, 5 Jan 2014 22:38:52 +0900 Subject: [PATCH 11/12] Fix 'gon' gem install failure. refs #5955 --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 29eb52a5bd7..79156028882 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -591,7 +591,7 @@ DEPENDENCIES gitlab_git (~> 4.0.0.pre) gitlab_meta (= 6.0) gitlab_omniauth-ldap (= 1.0.3) - gon! + gon (~> 5.0.0) grape (~> 0.6.1) grape-entity (~> 0.3.0) growl -- GitLab From 317362666be9358a8fccb4e0e9c4640bb1a2ef71 Mon Sep 17 00:00:00 2001 From: Jacob Vosmaer <contact@jacobvosmaer.nl> Date: Wed, 15 Jan 2014 15:16:19 +0100 Subject: [PATCH 12/12] Disable SSL peer verification for all webhooks SSL peer verification was silently enabled by the HTTParty upgrade in 8a54fda45957b3755f7c06e5c9b955c794488ff1. This patch restores the previous behaviour of GitLab 6.3 and earlier. --- app/models/web_hook.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/web_hook.rb b/app/models/web_hook.rb index c0aa3734917..8a5c4b6cd47 100644 --- a/app/models/web_hook.rb +++ b/app/models/web_hook.rb @@ -28,7 +28,7 @@ class WebHook < ActiveRecord::Base def execute(data) parsed_url = URI.parse(url) if parsed_url.userinfo.blank? - WebHook.post(url, body: data.to_json, headers: { "Content-Type" => "application/json" }) + WebHook.post(url, body: data.to_json, headers: { "Content-Type" => "application/json" }, verify: false) else post_url = url.gsub("#{parsed_url.userinfo}@", "") auth = { @@ -38,6 +38,7 @@ class WebHook < ActiveRecord::Base WebHook.post(post_url, body: data.to_json, headers: {"Content-Type" => "application/json"}, + verify: false, basic_auth: auth) end end -- GitLab