cicd-builder 0.9.13 → 0.9.14
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/lib/cicd/builder/mixlib/build.rb +3 -3
- data/lib/cicd/builder/mixlib/environment.rb +12 -0
- data/lib/cicd/builder/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZGU0MDk0MjEzOTYxNWVhNjlhNDVlNjA5NjU0MTVmOGUwZjk4ODI1ZQ==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
NjVhMGE4ZGZiNTcyNDgxOGJmOWVmZDY4MjM3MzBiYmQyY2JmMzRmYg==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MjhjNDQ0OGJkY2JkZTg4NWY1YzdjYTkwNjQxNDYyMmNlNDAwYjMxN2M5OWVl
|
10
|
+
ZjkxM2JkNGZmYTdlNzQ2MzRkZWFmNmRiNTM0YTU4Y2U3MTdhYTRjZjIyNTc0
|
11
|
+
NGZmZDFjNGVmZDUzNWZjODljOGEwOGQ2Y2Y4MmU4MGIwYThhN2M=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
MTFjNTdkNTRmNTk2NWVlN2NiMzE3N2VjMTMxNzFkNzI5NzlmMTVlMTA2NzBm
|
14
|
+
YzY2ZWQ4MDE2Yzg3ZGI1YmUzZWFhNjA3Y2QyNTAzZjMwZjE2YTE1ZjcwZmIz
|
15
|
+
ZmZkMjZjM2I0NzgzY2UyZjY2MzQzMDAzZWJjZDhjYTY0NDRlOTM=
|
@@ -31,13 +31,13 @@ module CiCd
|
|
31
31
|
# ---------------------------------------------------------------------------------------------------------------
|
32
32
|
def prepareBuild()
|
33
33
|
meta = {}
|
34
|
-
%w[ WORKSPACE PROJECT_NAME
|
34
|
+
%w[ WORKSPACE PROJECT_NAME ].each do |e|
|
35
35
|
unless ENV.has_key?(e)
|
36
36
|
raise "#{e} environment variable is required"
|
37
37
|
end
|
38
38
|
end
|
39
|
-
meta[:Version] =
|
40
|
-
meta[:Release] =
|
39
|
+
meta[:Version] = @vars[:version]
|
40
|
+
meta[:Release] = @vars[:release]
|
41
41
|
|
42
42
|
place = ''
|
43
43
|
begin
|
@@ -39,6 +39,18 @@ module CiCd
|
|
39
39
|
|
40
40
|
if ENV.has_key?('RELEASE')
|
41
41
|
@vars[:release] = ENV['RELEASE']
|
42
|
+
elsif File.exists?((version_file=File.join(ENV['REPO_DIR'], 'RELEASE')))
|
43
|
+
@vars[:release] = File.readlines(version_file).shift
|
44
|
+
else
|
45
|
+
raise "'RELEASE' was not provided in either environment or #{version_file} file"
|
46
|
+
end
|
47
|
+
|
48
|
+
if ENV.has_key?('VERSION')
|
49
|
+
@vars[:version] = ENV['VERSION']
|
50
|
+
elsif File.exists?((version_file=File.join(ENV['REPO_DIR'], 'VERSION')))
|
51
|
+
@vars[:version] = File.readlines(version_file).shift
|
52
|
+
else
|
53
|
+
raise "'VERSION' was not provided in either environment or #{version_file} file"
|
42
54
|
end
|
43
55
|
|
44
56
|
if ENV.has_key?('BUILD_STORE')
|
data/lib/cicd/builder/version.rb
CHANGED
@@ -4,7 +4,7 @@ module CiCd
|
|
4
4
|
# file = File.expand_path("#{File.dirname(__FILE__)}/../../../VERSION")
|
5
5
|
# lines = File.readlines(file)
|
6
6
|
# version = lines[0]
|
7
|
-
version = '0.9.
|
7
|
+
version = '0.9.14'
|
8
8
|
VERSION = version unless const_defined?('VERSION')
|
9
9
|
major, minor, tiny = VERSION.split('.')
|
10
10
|
MAJOR = major unless const_defined?('MAJOR')
|