gitlab_git 6.0.0 → 6.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/VERSION +1 -1
  3. data/lib/gitlab_git/repository.rb +11 -1
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2ce03ca6007fea80f20f967c1ee4eba934419366
4
- data.tar.gz: a43107fb46facf70055e47966394ba37e38ab0f9
3
+ metadata.gz: 50120b4f1056d8df68e3dc4329dfd8a0518cf9c9
4
+ data.tar.gz: eec963ccfdf12d379af1c3a20f57f2578df88ad2
5
5
  SHA512:
6
- metadata.gz: 47f0f2c5c33c2e363dfd2e8e08114495dd3a1331a6011bc86bf0188fca3fde40a564dacc852332be281fe32985fbc4c8d647736c220e36400d99c078607f157d
7
- data.tar.gz: 3bb88bbc2e04d95a7fb1c66497ac4eecdbf226c90e863ac2c8b7ce30ff509ac0c89d559f1b0ed1ecc96bdc0c565932160befd652811fc876d2fbb7dff38b47e6
6
+ metadata.gz: 34f2c7a605650d5e1393c1c359fa1944ee68d752bcc7230023134f3c2272dd0d3da90be6e4dd2d0542b65fc9d4bdbbbcca186337f007d0c3cc4cde5404bfc6e8
7
+ data.tar.gz: ee25fdcaa3dafcf58ad48c72dee6fb9b3747b54e5911b453c96a9528c5e575f0a5b4e4134edbb109f810021e993ad53d2a83ae3847143cf5e8a4857efb8289f2
data/VERSION CHANGED
@@ -1 +1 @@
1
- 6.0.0
1
+ 6.0.1
@@ -2,6 +2,7 @@
2
2
  # We dont want to use grit objects inside app/
3
3
  # It helps us easily migrate to rugged in future
4
4
  require_relative 'encoding_herlper'
5
+ require 'tempfile'
5
6
 
6
7
  module Gitlab
7
8
  module Git
@@ -164,8 +165,17 @@ module Gitlab
164
165
 
165
166
  # Create file if not exists
166
167
  unless File.exists?(file_path)
168
+ # create archive in temp file
169
+ tmp_file = Tempfile.new('gitlab-archive-repo')
170
+ self.grit.archive_to_file(ref, prefix, tmp_file.path, git_archive_format, pipe_cmd)
171
+
172
+ # move temp file to persisted location
167
173
  FileUtils.mkdir_p File.dirname(file_path)
168
- file = self.grit.archive_to_file(ref, prefix, file_path, git_archive_format, pipe_cmd)
174
+ FileUtils.move(tmp_file.path, file_path)
175
+
176
+ # delte temp file
177
+ tmp_file.close
178
+ tmp_file.unlink
169
179
  end
170
180
 
171
181
  file_path
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab_git
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.0
4
+ version: 6.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitriy Zaporozhets
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-11 00:00:00.000000000 Z
11
+ date: 2014-07-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gitlab-linguist