Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-02-06 21:08:54 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-02-06 21:08:54 +0300
commit0d6fa033121a9bef708b8f2de186c4034c61d4a3 (patch)
tree851d65a09efbffa114c9a273e590d55cfb1436ab /lib/gitlab/git
parent0eb3d2f799ce4f4de87fb9fc6fd98e592323bc89 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/git')
-rw-r--r--lib/gitlab/git/repository.rb10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/gitlab/git/repository.rb b/lib/gitlab/git/repository.rb
index 807cfb5f93f..840a70e3ae5 100644
--- a/lib/gitlab/git/repository.rb
+++ b/lib/gitlab/git/repository.rb
@@ -636,10 +636,9 @@ module Gitlab
end
# Delete the specified branch from the repository
+ # Note: No Git hooks are executed for this action
def delete_branch(branch_name)
- wrapped_gitaly_errors do
- gitaly_ref_client.delete_branch(branch_name)
- end
+ write_ref(branch_name, Gitlab::Git::BLANK_SHA)
rescue CommandError => e
raise DeleteBranchError, e
end
@@ -651,14 +650,13 @@ module Gitlab
end
# Create a new branch named **ref+ based on **stat_point+, HEAD by default
+ # Note: No Git hooks are executed for this action
#
# Examples:
# create_branch("feature")
# create_branch("other-feature", "master")
def create_branch(ref, start_point = "HEAD")
- wrapped_gitaly_errors do
- gitaly_ref_client.create_branch(ref, start_point)
- end
+ write_ref(ref, start_point)
end
# If `mirror_refmap` is present the remote is set as mirror with that mapping