Skip to content
Snippets Groups Projects

Don't execute git hooks if you create branch as part of other change

Merged Kamil Trzciński requested to merge fix-git-hooks-when-creating-file into master
All threads resolved!
Compare and
12 files
+ 200
81
Compare changes
  • Side-by-side
  • Inline
Files
12
+ 11
0
@@ -988,6 +988,17 @@ def rename_repo
Gitlab::UploadsTransfer.new.rename_project(path_was, path, namespace.path)
end
def fetch_ref(source_project, branch_name, ref)
repository.fetch_ref(
source_project.repository.path_to_repo,
"refs/heads/#{ref}",
"refs/heads/#{branch_name}"
)
repository.after_create_branch
repository.find_branch(branch_name)
end
# Expires various caches before a project is renamed.
def expire_caches_before_rename(old_path)
repo = Repository.new(old_path, self)
Loading