knife-axe 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +11 -3
- data/lib/chef/knife/axe_env.rb +0 -13
- metadata +1 -1
data/README.md
CHANGED
@@ -1,12 +1,20 @@
|
|
1
1
|
knife-axe
|
2
2
|
=========
|
3
|
+
knife axe prints diff of objects (environment,data_bag,role) before uploading them.
|
3
4
|
|
4
|
-
|
5
|
+
![](https://raw2.github.com/faja/images/master/knife-axe/knife-axe.png)
|
6
|
+
|
7
|
+
### Installation:
|
8
|
+
|
9
|
+
```
|
10
|
+
$ gem install knife-axe
|
11
|
+
```
|
12
|
+
or
|
5
13
|
```
|
6
|
-
$ gem install diffy
|
7
14
|
$ cp axe*.rb ~/.chef/plugins/knife
|
8
15
|
```
|
9
|
-
|
16
|
+
|
17
|
+
### Usage:
|
10
18
|
```
|
11
19
|
$ knife axe role ~/chef-repo/role/role42.rb
|
12
20
|
$ knife axe env ~/chef-repo/environments/environment42.rb
|
data/lib/chef/knife/axe_env.rb
CHANGED
@@ -9,19 +9,6 @@ class Chef
|
|
9
9
|
|
10
10
|
banner 'knife axe env FILENAME'
|
11
11
|
|
12
|
-
def yesno
|
13
|
-
puts "Continue? [y/n]"
|
14
|
-
yn = STDIN.gets.chomp()
|
15
|
-
if yn == 'y' or yn == 'Y'
|
16
|
-
return 0
|
17
|
-
elsif yn == 'n' or yn == 'N'
|
18
|
-
puts "You chose 'n'. I'm done here."
|
19
|
-
exit 0
|
20
|
-
else
|
21
|
-
yesno
|
22
|
-
end
|
23
|
-
end
|
24
|
-
|
25
12
|
def run
|
26
13
|
if @name_args[0].nil?
|
27
14
|
show_usage
|