cody 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/cody/dsl/project.rb +15 -2
- data/lib/cody/project.rb +0 -1
- data/lib/cody/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f7a7aef69b13119002518200397cd29e961a44bcc5b1af86ee8b7b10257e79bb
|
4
|
+
data.tar.gz: 7c5da7d1e3a0f1387df351d86ae77c28b8dde56554461c69085c71c7cdf61764
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d7d882be7a9814bba876894c67f4fbe436893d97882d6cfab2af80b56dd39df89ddb126f208da8b13e3df6d18eef3375850cc6522158014047d41ff10f8e9cc3
|
7
|
+
data.tar.gz: 4023dfde8116141efe8a83be416882c6d44c64bdd228918bee6ac13735d8d706b3474fcbe2b4cb623f1e2241437a00d92093f998fb1ff34ff86e68cb814c4d8b
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,9 @@
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
4
4
|
This project *tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
|
5
5
|
|
6
|
+
## [1.0.2]
|
7
|
+
- #30 Allow multiple git providers
|
8
|
+
|
6
9
|
## [1.0.1]
|
7
10
|
- fix EventsRuleRole Service camelcase
|
8
11
|
|
data/lib/cody/dsl/project.rb
CHANGED
@@ -32,6 +32,16 @@ module Cody::Dsl
|
|
32
32
|
@properties[:Source][:Location] = url
|
33
33
|
end
|
34
34
|
|
35
|
+
# Convenience wrapper methods
|
36
|
+
def git_provider(type="GITHUB")
|
37
|
+
@properties[:Source][:Type] = type
|
38
|
+
end
|
39
|
+
|
40
|
+
# Convenience wrapper methods
|
41
|
+
def git_branch(branch_or_tag)
|
42
|
+
@properties[:SourceVersion] = branch_or_tag
|
43
|
+
end
|
44
|
+
|
35
45
|
def buildspec(file=".cody/buildspec.yaml")
|
36
46
|
@properties[:Source][:BuildSpec] = file
|
37
47
|
end
|
@@ -49,14 +59,17 @@ module Cody::Dsl
|
|
49
59
|
|
50
60
|
def github_source(options={})
|
51
61
|
source = {
|
52
|
-
Type: "GITHUB",
|
62
|
+
Type: options[:Type] || "GITHUB",
|
53
63
|
Location: options[:Location],
|
54
64
|
GitCloneDepth: 1,
|
55
65
|
GitSubmodulesConfig: { fetch_submodules: true },
|
56
66
|
BuildSpec: options[:BuildSpec] || ".cody/buildspec.yml", # options[:Buildspec] accounts for type already
|
57
|
-
ReportBuildStatus: true,
|
58
67
|
}
|
59
68
|
|
69
|
+
if source[:Type] =~ /GITHUB/
|
70
|
+
source[:ReportBuildStatus] = true
|
71
|
+
end
|
72
|
+
|
60
73
|
if options[:OauthToken]
|
61
74
|
source[:Auth] = {
|
62
75
|
Type: "OAUTH",
|
data/lib/cody/project.rb
CHANGED
data/lib/cody/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cody
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tung Nguyen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-10-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|