mswin-build 1.3.1 → 1.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mswin-build/builder.rb +24 -4
- data/lib/mswin-build/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2fed59177b86648df08cfaed325f177df4788bfe563e30e7b9765703ee191b7a
|
4
|
+
data.tar.gz: 9454943763808038cfd0e84ccb149cee9de8a4b3adaaa3cdab176a6ca7402939
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c3ddaa5bbb882dc87f5696aa2a5051eb824f28eeb5a2ec9babcd684dd2688cb1ecf1b6c2a59408b8c1df00bfbd983ed427a72afab1279aa937fc3576ee9ef63c
|
7
|
+
data.tar.gz: 45343b1e3d50fedb564a5dbc48a10587a21aabad0ffd8e3032893c7e8431890fe82d53b5ee986940d9947b96b239a9013e96d66cf00448422dc4cf8bc55994b7
|
data/lib/mswin-build/builder.rb
CHANGED
@@ -52,6 +52,7 @@ module MswinBuild
|
|
52
52
|
@config["timeout"]["svn/ruby"] ||= @config["timeout"]["default"]
|
53
53
|
@config["timeout"]["svn/info"] ||= @config["timeout"]["default_short"]
|
54
54
|
@config["timeout"]["git/ruby"] ||= @config["timeout"]["default"]
|
55
|
+
@config["timeout"]["git/info"] ||= @config["timeout"]["default_short"]
|
55
56
|
@config["timeout"]["configure"] ||= @config["timeout"]["default"]
|
56
57
|
@config["timeout"]["cc-version"] ||= @config["timeout"]["default_short"]
|
57
58
|
@config["timeout"]["miniruby"] ||= @config["timeout"]["default"]
|
@@ -365,6 +366,16 @@ module MswinBuild
|
|
365
366
|
Dir.chdir(tmpdir) do
|
366
367
|
do_command(io, "git/ruby", "#{@config['git']} clone -q --branch #{@config['branch']} --depth 1 --single-branch #{@config['repository']} ruby")
|
367
368
|
end
|
369
|
+
@data[:svn_url] = "https://github.com/ruby/ruby"
|
370
|
+
|
371
|
+
# git-info/ruby
|
372
|
+
Dir.chdir(File.join(tmpdir, "ruby")) do
|
373
|
+
do_command(io, "git-info/ruby", "#{@config['git']} log -1 2> NUL", true) do |s|
|
374
|
+
if /^commit ([\da-f]+)$/ =~ s
|
375
|
+
@data[:commit_hash] = $1
|
376
|
+
end
|
377
|
+
end
|
378
|
+
end
|
368
379
|
else
|
369
380
|
# svn/ruby
|
370
381
|
Dir.chdir(tmpdir) do
|
@@ -623,7 +634,7 @@ module MswinBuild
|
|
623
634
|
line = h(line) unless /^<a / =~ line
|
624
635
|
out.write line
|
625
636
|
warns += line.scan(/warn/i).length
|
626
|
-
if File.basename(io.path) == "checkout" && /^(?:SVN )?Last Changed Rev: (\d+)$/ =~ line
|
637
|
+
if !@is_git && File.basename(io.path) == "checkout" && /^(?:SVN )?Last Changed Rev: (\d+)$/ =~ line
|
627
638
|
revision = $1
|
628
639
|
end
|
629
640
|
end
|
@@ -665,12 +676,21 @@ module MswinBuild
|
|
665
676
|
title << @data[:warn]
|
666
677
|
end
|
667
678
|
url = @data.delete(:svn_url)
|
668
|
-
|
669
|
-
|
679
|
+
commit_hash = @data.delete(:commit_hash)
|
680
|
+
if revision || commit_hash
|
681
|
+
if @is_git
|
682
|
+
@data[:ruby_rev] = commit_hash[0, 11]
|
683
|
+
else
|
684
|
+
@data[:ruby_rev] = "r#{revision}"
|
685
|
+
end
|
670
686
|
@title.unshift(@data[:ruby_rev])
|
671
687
|
title.unshift(@data[:ruby_rev])
|
672
688
|
@data[:version] = "#{@data[:ruby_rev]} #{@data[:version]}"
|
673
|
-
@
|
689
|
+
if @is_git
|
690
|
+
@data[url] = commit_hash
|
691
|
+
else
|
692
|
+
@data[url] = revision
|
693
|
+
end
|
674
694
|
end
|
675
695
|
@data.each_pair do |k, v|
|
676
696
|
if k.is_a?(String) && /^failure_/ =~ k
|
data/lib/mswin-build/version.rb
CHANGED