autobuild 1.6.2.b10 → 1.6.2.b11

Sign up to get free protection for your applications and to get access to all the features.
@@ -203,7 +203,7 @@ module Autobuild
203
203
  end
204
204
  end
205
205
 
206
- status = merge_status(remote_commit)
206
+ status = merge_status(package, remote_commit)
207
207
  `git diff --quiet`
208
208
  if $?.exitstatus != 0
209
209
  status.uncommitted_code = true
@@ -279,7 +279,16 @@ module Autobuild
279
279
  end
280
280
  end
281
281
 
282
- def merge_status(fetch_commit, reference_commit = "HEAD")
282
+ # Computes the update status to update a branch whose tip is at
283
+ # reference_commit (which can be a symbolic reference) using the
284
+ # fetch_commit commit
285
+ #
286
+ # I.e. this compute what happens if one would do
287
+ #
288
+ # git checkout reference_commit
289
+ # git merge fetch_commit
290
+ #
291
+ def merge_status(package, fetch_commit, reference_commit = "HEAD")
283
292
  common_commit = `git merge-base #{reference_commit} #{fetch_commit}`.chomp
284
293
  if $?.exitstatus != 0
285
294
  raise PackageException.new(package, 'import'), "failed to find the merge-base between #{reference_commit} and #{fetch_commit}. Are you sure these commits exist ?"
@@ -314,12 +323,12 @@ module Autobuild
314
323
  # If we are tracking a commit/tag, just check it out and return
315
324
  if commit || tag
316
325
  target_commit = (commit || tag)
317
- status_to_head = merge_status(target_commit, "HEAD")
326
+ status_to_head = merge_status(package, target_commit, "HEAD")
318
327
  if status_to_head.status == Status::UP_TO_DATE
319
328
  # Check if by any chance we could switch back to a
320
329
  # proper branch instead of having a detached HEAD
321
330
  if detached_head?
322
- status_to_remote = merge_status(target_commit, fetch_commit)
331
+ status_to_remote = merge_status(package, target_commit, fetch_commit)
323
332
  if status_to_remote.status != Status::UP_TO_DATE
324
333
  package.message " the package is on a detached HEAD because of commit pinning"
325
334
  return
@@ -331,11 +340,11 @@ module Autobuild
331
340
  raise PackageException.new(package, 'import'), "checking out the specified commit #{target_commit} would be a non-simple operation (i.e. the current state of the repository is not a linear relationship with the specified commit), do it manually"
332
341
  end
333
342
 
334
- status_to_remote = merge_status(target_commit, fetch_commit)
343
+ status_to_remote = merge_status(package, target_commit, fetch_commit)
335
344
  if status_to_remote.status != Status::UP_TO_DATE
336
345
  # Try very hard to avoid creating a detached HEAD
337
346
  if local_branch
338
- status_to_branch = merge_status(target_commit, local_branch)
347
+ status_to_branch = merge_status(package, target_commit, local_branch)
339
348
  if status_to_branch.status == Status::UP_TO_DATE # Checkout the branch
340
349
  package.message " checking out specific commit %s for %s. It will checkout branch %s." % [target_commit.to_s, package.name, local_branch]
341
350
  Subprocess.run(package, :import, Autobuild.tool('git'), 'checkout', local_branch)
@@ -364,7 +373,7 @@ module Autobuild
364
373
  end
365
374
  end
366
375
 
367
- status = merge_status(fetch_commit)
376
+ status = merge_status(package, fetch_commit)
368
377
  if status.needs_update?
369
378
  if !merge? && status.status == Status::NEEDS_MERGE
370
379
  raise PackageException.new(package, 'import'), "the local branch '#{local_branch}' and the remote branch #{branch} of #{package.name} have diverged, and I therefore refuse to update automatically. Go into #{package.srcdir} and either reset the local branch or merge the remote changes"
@@ -395,7 +404,7 @@ module Autobuild
395
404
 
396
405
  # If we are tracking a commit/tag, just check it out
397
406
  if commit || tag
398
- status = merge_status(commit || tag)
407
+ status = merge_status(package, commit || tag)
399
408
  if status.status != Status::UP_TO_DATE
400
409
  package.message " checking out specific commit for %s. This will create a detached HEAD." % [package.name]
401
410
  Subprocess.run(package, :import, Autobuild.tool('git'), 'checkout', commit || tag)
@@ -1,5 +1,5 @@
1
1
  module Autobuild
2
- VERSION = "1.6.2.b10" unless defined? Autobuild::VERSION
2
+ VERSION = "1.6.2.b11" unless defined? Autobuild::VERSION
3
3
  end
4
4
 
5
5
 
metadata CHANGED
@@ -1,73 +1,97 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: autobuild
3
- version: !ruby/object:Gem::Version
4
- version: 1.6.2.b10
3
+ version: !ruby/object:Gem::Version
4
+ hash: -3493996294
5
5
  prerelease: 6
6
+ segments:
7
+ - 1
8
+ - 6
9
+ - 2
10
+ - b
11
+ - 11
12
+ version: 1.6.2.b11
6
13
  platform: ruby
7
- authors:
14
+ authors:
8
15
  - Sylvain Joyeux
9
16
  autorequire:
10
17
  bindir: bin
11
18
  cert_chain: []
12
- date: 2012-10-05 00:00:00.000000000 Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
19
+
20
+ date: 2012-10-15 00:00:00 Z
21
+ dependencies:
22
+ - !ruby/object:Gem::Dependency
15
23
  name: rake
16
- requirement: &14268080 !ruby/object:Gem::Requirement
24
+ prerelease: false
25
+ requirement: &id001 !ruby/object:Gem::Requirement
17
26
  none: false
18
- requirements:
19
- - - ! '>='
20
- - !ruby/object:Gem::Version
27
+ requirements:
28
+ - - ">="
29
+ - !ruby/object:Gem::Version
30
+ hash: 3
31
+ segments:
32
+ - 0
33
+ - 7
34
+ - 0
21
35
  version: 0.7.0
22
36
  type: :runtime
23
- prerelease: false
24
- version_requirements: *14268080
25
- - !ruby/object:Gem::Dependency
37
+ version_requirements: *id001
38
+ - !ruby/object:Gem::Dependency
26
39
  name: utilrb
27
- requirement: &14265920 !ruby/object:Gem::Requirement
40
+ prerelease: false
41
+ requirement: &id002 !ruby/object:Gem::Requirement
28
42
  none: false
29
- requirements:
30
- - - ! '>='
31
- - !ruby/object:Gem::Version
43
+ requirements:
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ hash: 29
47
+ segments:
48
+ - 1
49
+ - 3
50
+ - 3
32
51
  version: 1.3.3
33
52
  type: :runtime
34
- prerelease: false
35
- version_requirements: *14265920
36
- - !ruby/object:Gem::Dependency
53
+ version_requirements: *id002
54
+ - !ruby/object:Gem::Dependency
37
55
  name: rdoc
38
- requirement: &14264700 !ruby/object:Gem::Requirement
56
+ prerelease: false
57
+ requirement: &id003 !ruby/object:Gem::Requirement
39
58
  none: false
40
- requirements:
59
+ requirements:
41
60
  - - ~>
42
- - !ruby/object:Gem::Version
43
- version: '3.10'
61
+ - !ruby/object:Gem::Version
62
+ hash: 19
63
+ segments:
64
+ - 3
65
+ - 10
66
+ version: "3.10"
44
67
  type: :development
45
- prerelease: false
46
- version_requirements: *14264700
47
- - !ruby/object:Gem::Dependency
68
+ version_requirements: *id003
69
+ - !ruby/object:Gem::Dependency
48
70
  name: hoe
49
- requirement: &14263180 !ruby/object:Gem::Requirement
71
+ prerelease: false
72
+ requirement: &id004 !ruby/object:Gem::Requirement
50
73
  none: false
51
- requirements:
74
+ requirements:
52
75
  - - ~>
53
- - !ruby/object:Gem::Version
54
- version: '3.0'
76
+ - !ruby/object:Gem::Version
77
+ hash: 5
78
+ segments:
79
+ - 3
80
+ - 1
81
+ version: "3.1"
55
82
  type: :development
56
- prerelease: false
57
- version_requirements: *14263180
58
- description: Collection of classes to handle build systems (CMake, autotools, ...)
59
- and import mechanisms (tarballs, CVS, SVN, git, ...). It also offers a Rake integration
60
- to import and build such software packages. It is the backbone of the autoproj (http://rock-robotics.org/autoproj)
61
- integrated software project management tool.
83
+ version_requirements: *id004
84
+ description: Collection of classes to handle build systems (CMake, autotools, ...) and import mechanisms (tarballs, CVS, SVN, git, ...). It also offers a Rake integration to import and build such software packages. It is the backbone of the autoproj (http://rock-robotics.org/autoproj) integrated software project management tool.
62
85
  email: rock-dev@dfki.de
63
- executables:
86
+ executables:
64
87
  - autobuild
65
88
  extensions: []
66
- extra_rdoc_files:
89
+
90
+ extra_rdoc_files:
67
91
  - Changes.txt
68
92
  - Manifest.txt
69
93
  - README.txt
70
- files:
94
+ files:
71
95
  - Changes.txt
72
96
  - Manifest.txt
73
97
  - README.txt
@@ -113,32 +137,42 @@ files:
113
137
  - .gemtest
114
138
  homepage: http://rock-robotics.org/stable/documentation/autoproj
115
139
  licenses: []
140
+
116
141
  post_install_message:
117
- rdoc_options:
142
+ rdoc_options:
118
143
  - --main
119
144
  - README.txt
120
- require_paths:
145
+ require_paths:
121
146
  - lib
122
- required_ruby_version: !ruby/object:Gem::Requirement
147
+ required_ruby_version: !ruby/object:Gem::Requirement
123
148
  none: false
124
- requirements:
125
- - - ! '>='
126
- - !ruby/object:Gem::Version
127
- version: '0'
128
- required_rubygems_version: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - ">="
151
+ - !ruby/object:Gem::Version
152
+ hash: 3
153
+ segments:
154
+ - 0
155
+ version: "0"
156
+ required_rubygems_version: !ruby/object:Gem::Requirement
129
157
  none: false
130
- requirements:
131
- - - ! '>'
132
- - !ruby/object:Gem::Version
158
+ requirements:
159
+ - - ">"
160
+ - !ruby/object:Gem::Version
161
+ hash: 25
162
+ segments:
163
+ - 1
164
+ - 3
165
+ - 1
133
166
  version: 1.3.1
134
167
  requirements: []
168
+
135
169
  rubyforge_project: autobuild
136
- rubygems_version: 1.8.11
170
+ rubygems_version: 1.8.24
137
171
  signing_key:
138
172
  specification_version: 3
139
173
  summary: Library to handle build systems and import mechanisms
140
- test_files:
141
- - test/test_import_cvs.rb
142
- - test/test_subcommand.rb
174
+ test_files:
143
175
  - test/test_import_svn.rb
144
176
  - test/test_import_tar.rb
177
+ - test/test_subcommand.rb
178
+ - test/test_import_cvs.rb