knife-sharp 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +2 -0
- data/Gemfile.lock +55 -24
- data/README.md +4 -5
- data/knife-sharp.gemspec +0 -1
- data/lib/chef/knife/sharp-align.rb +0 -1
- data/lib/knife-sharp.rb +1 -1
- data/lib/knife-sharp/common.rb +6 -4
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1883776ced8a7c5cceaf4732195ef8ac9aa52faf
|
4
|
+
data.tar.gz: 7fe5dd589ce02228a9068fc0693dc69bebe57e3d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 97bc72e991176812e9b12b73d5ef31a8e3ceec5bf766942e3c344ad311fd3ced8944ce81bff56e357ec75967c2bf718b9bf8174b4fa5f72b0e8aaebe034b8859
|
7
|
+
data.tar.gz: 9ad43019d1ca1cf77f06d264ac0ecae3ab014cc381ad4853576e36e1621da46d463e77b9180b2ec6e3cd151c7aaba4b90c6672eee0972913278f6c9c34c9620f
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,17 +1,18 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
knife-sharp (0.
|
4
|
+
knife-sharp (0.6.1)
|
5
5
|
chef (>= 11)
|
6
|
-
grit (~> 2.5)
|
7
6
|
|
8
7
|
GEM
|
8
|
+
remote: https://rubygems.org/
|
9
9
|
specs:
|
10
|
-
|
11
|
-
|
10
|
+
builder (3.2.2)
|
11
|
+
chef (12.2.1)
|
12
|
+
chef-zero (~> 4.0)
|
12
13
|
diff-lcs (~> 1.2, >= 1.2.4)
|
13
14
|
erubis (~> 2.7)
|
14
|
-
ffi-yajl (
|
15
|
+
ffi-yajl (>= 1.2, < 3.0)
|
15
16
|
highline (~> 1.6, >= 1.6.9)
|
16
17
|
mixlib-authentication (~> 1.3)
|
17
18
|
mixlib-cli (~> 1.4)
|
@@ -23,8 +24,14 @@ GEM
|
|
23
24
|
ohai (~> 8.0)
|
24
25
|
plist (~> 3.1.0)
|
25
26
|
pry (~> 0.9)
|
26
|
-
|
27
|
-
|
27
|
+
rspec-core (~> 3.2)
|
28
|
+
rspec-expectations (~> 3.2)
|
29
|
+
rspec-mocks (~> 3.2)
|
30
|
+
rspec_junit_formatter (~> 0.2.0)
|
31
|
+
serverspec (~> 2.7)
|
32
|
+
specinfra (~> 2.10)
|
33
|
+
chef-zero (4.2.1)
|
34
|
+
ffi-yajl (>= 1.1, < 3.0)
|
28
35
|
hashie (~> 2.0)
|
29
36
|
mixlib-log (~> 1.3)
|
30
37
|
rack
|
@@ -32,56 +39,80 @@ GEM
|
|
32
39
|
coderay (1.1.0)
|
33
40
|
diff-lcs (1.2.5)
|
34
41
|
erubis (2.7.0)
|
35
|
-
ffi (1.9.
|
36
|
-
ffi-yajl (
|
42
|
+
ffi (1.9.8)
|
43
|
+
ffi-yajl (2.0.0)
|
37
44
|
ffi (~> 1.5)
|
38
45
|
libyajl2 (~> 1.2)
|
39
|
-
grit (2.5.0)
|
40
|
-
diff-lcs (~> 1.1)
|
41
|
-
mime-types (~> 1.15)
|
42
|
-
posix-spawn (~> 0.3.6)
|
43
46
|
hashie (2.1.2)
|
44
|
-
highline (1.
|
47
|
+
highline (1.7.1)
|
45
48
|
ipaddress (0.8.0)
|
46
49
|
libyajl2 (1.2.0)
|
47
50
|
method_source (0.8.2)
|
48
|
-
mime-types (
|
51
|
+
mime-types (2.4.3)
|
49
52
|
mixlib-authentication (1.3.0)
|
50
53
|
mixlib-log
|
51
54
|
mixlib-cli (1.5.0)
|
52
55
|
mixlib-config (2.1.0)
|
53
56
|
mixlib-log (1.6.0)
|
54
57
|
mixlib-shellout (2.0.1)
|
55
|
-
|
58
|
+
multi_json (1.11.0)
|
59
|
+
net-scp (1.2.1)
|
60
|
+
net-ssh (>= 2.6.5)
|
56
61
|
net-ssh (2.9.2)
|
57
62
|
net-ssh-gateway (1.2.0)
|
58
63
|
net-ssh (>= 2.6.5)
|
59
|
-
net-ssh-multi (1.2.
|
64
|
+
net-ssh-multi (1.2.1)
|
60
65
|
net-ssh (>= 2.6.5)
|
61
66
|
net-ssh-gateway (>= 1.2.0)
|
62
|
-
ohai (8.0
|
67
|
+
ohai (8.2.0)
|
63
68
|
ffi (~> 1.9)
|
64
|
-
ffi-yajl (
|
69
|
+
ffi-yajl (>= 1.1, < 3.0)
|
65
70
|
ipaddress
|
66
|
-
mime-types (~>
|
71
|
+
mime-types (~> 2.0)
|
67
72
|
mixlib-cli
|
68
73
|
mixlib-config (~> 2.0)
|
69
74
|
mixlib-log
|
70
75
|
mixlib-shellout (~> 2.0)
|
71
|
-
net-dhcp
|
72
76
|
rake (~> 10.1)
|
73
77
|
systemu (~> 2.6.4)
|
74
78
|
wmi-lite (~> 1.0)
|
75
79
|
plist (3.1.0)
|
76
|
-
posix-spawn (0.3.9)
|
77
80
|
pry (0.10.1)
|
78
81
|
coderay (~> 1.1.0)
|
79
82
|
method_source (~> 0.8.1)
|
80
83
|
slop (~> 3.4)
|
81
84
|
rack (1.6.0)
|
82
|
-
rake (10.
|
85
|
+
rake (10.4.2)
|
86
|
+
rspec (3.2.0)
|
87
|
+
rspec-core (~> 3.2.0)
|
88
|
+
rspec-expectations (~> 3.2.0)
|
89
|
+
rspec-mocks (~> 3.2.0)
|
90
|
+
rspec-core (3.2.3)
|
91
|
+
rspec-support (~> 3.2.0)
|
92
|
+
rspec-expectations (3.2.1)
|
93
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
94
|
+
rspec-support (~> 3.2.0)
|
95
|
+
rspec-its (1.2.0)
|
96
|
+
rspec-core (>= 3.0.0)
|
97
|
+
rspec-expectations (>= 3.0.0)
|
98
|
+
rspec-mocks (3.2.1)
|
99
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
100
|
+
rspec-support (~> 3.2.0)
|
101
|
+
rspec-support (3.2.2)
|
102
|
+
rspec_junit_formatter (0.2.0)
|
103
|
+
builder (< 4)
|
104
|
+
rspec (>= 2, < 4)
|
105
|
+
rspec-core (!= 2.12.0)
|
106
|
+
serverspec (2.14.1)
|
107
|
+
multi_json
|
108
|
+
rspec (~> 3.0)
|
109
|
+
rspec-its
|
110
|
+
specinfra (~> 2.25)
|
83
111
|
slop (3.6.0)
|
84
|
-
|
112
|
+
specinfra (2.28.2)
|
113
|
+
net-scp
|
114
|
+
net-ssh
|
115
|
+
systemu (2.6.5)
|
85
116
|
uuidtools (2.1.5)
|
86
117
|
wmi-lite (1.0.0)
|
87
118
|
|
data/README.md
CHANGED
@@ -172,9 +172,6 @@ The activation of this rollback feature and its storage dir can be configured in
|
|
172
172
|
|
173
173
|
# Configuration
|
174
174
|
|
175
|
-
Dependencies :
|
176
|
-
* grit
|
177
|
-
|
178
175
|
The plugin will search in 2 places for its config file :
|
179
176
|
* "/etc/sharp-config.yml"
|
180
177
|
* "~/.chef/sharp-config.yml"
|
@@ -192,8 +189,9 @@ environment_path '/home/jamiez/chef/environments'
|
|
192
189
|
```
|
193
190
|
in knife.rb
|
194
191
|
|
195
|
-
##
|
196
|
-
|
192
|
+
## Current git branch
|
193
|
+
|
194
|
+
knife-sharp will check that the given branch is the active one in the chef repo. Chef repo path has to be specified in sharp-config.yml file:
|
197
195
|
|
198
196
|
```yaml
|
199
197
|
global:
|
@@ -203,6 +201,7 @@ global:
|
|
203
201
|
As we version more than the cookbooks in the repo.
|
204
202
|
|
205
203
|
## Logging
|
204
|
+
|
206
205
|
It's good to have things logged. The plugin can do it for you. Add this to your config file
|
207
206
|
```yaml
|
208
207
|
logging:
|
data/knife-sharp.gemspec
CHANGED
data/lib/knife-sharp.rb
CHANGED
data/lib/knife-sharp/common.rb
CHANGED
@@ -23,11 +23,13 @@ module KnifeSharp
|
|
23
23
|
def ensure_correct_branch_provided!
|
24
24
|
# Checking current branch
|
25
25
|
given_branch = @name_args.first
|
26
|
-
current_branch = Grit::Repo.new(sharp_config["global"]["git_cookbook_path"]).head.name
|
27
26
|
|
28
|
-
|
29
|
-
|
30
|
-
|
27
|
+
Dir.chdir(sharp_config["global"]["git_cookbook_path"]) do
|
28
|
+
current_branch = %x(git rev-parse --abbrev-ref HEAD).chomp
|
29
|
+
if given_branch != current_branch
|
30
|
+
ui.error "Git repo is actually on branch #{current_branch} but you want to align using #{given_branch}. Checkout to the desired one."
|
31
|
+
exit 1
|
32
|
+
end
|
31
33
|
end
|
32
34
|
end
|
33
35
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: knife-sharp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nicolas Szalay
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-04-
|
12
|
+
date: 2015-04-17 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: chef
|
@@ -25,20 +25,6 @@ dependencies:
|
|
25
25
|
- - ">="
|
26
26
|
- !ruby/object:Gem::Version
|
27
27
|
version: '11'
|
28
|
-
- !ruby/object:Gem::Dependency
|
29
|
-
name: grit
|
30
|
-
requirement: !ruby/object:Gem::Requirement
|
31
|
-
requirements:
|
32
|
-
- - "~>"
|
33
|
-
- !ruby/object:Gem::Version
|
34
|
-
version: '2.5'
|
35
|
-
type: :runtime
|
36
|
-
prerelease: false
|
37
|
-
version_requirements: !ruby/object:Gem::Requirement
|
38
|
-
requirements:
|
39
|
-
- - "~>"
|
40
|
-
- !ruby/object:Gem::Version
|
41
|
-
version: '2.5'
|
42
28
|
description: Sharpen your knife
|
43
29
|
email:
|
44
30
|
- nico@rottenbytes.info
|