diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2017-10-05 17:30:44 +0800 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2017-10-05 17:30:44 +0800 |
commit | e25abf5be63a6fc124d9fb33d042897fb2a09d82 (patch) | |
tree | f5f04bfd76e21ef1e6f314cc9584de516daa3237 | |
parent | 6ba961499c732d930d4939c0fa3743afa20fd2a8 (diff) | |
download | gitlab-ce-e25abf5be63a6fc124d9fb33d042897fb2a09d82.tar.gz |
Use simple path for tmp ref, avoiding extra dir
So that we don't have to worry about cleaning empty
directories later. This was brought up at:
https://gitlab.com/gitlab-org/gitlab-ce/issues/38689#note_42242988
-rw-r--r-- | lib/gitlab/git/repository.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/git/repository.rb b/lib/gitlab/git/repository.rb index 89b654253cb..e42bbb659b4 100644 --- a/lib/gitlab/git/repository.rb +++ b/lib/gitlab/git/repository.rb @@ -990,7 +990,7 @@ module Gitlab tmp_ref = fetch_ref( start_repository, source_ref: "#{Gitlab::Git::BRANCH_REF_PREFIX}#{start_branch_name}", - target_ref: "refs/tmp/#{SecureRandom.hex}/head" + target_ref: "refs/tmp/#{SecureRandom.hex}" ) yield commit(sha) |