awskit 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 787af9be6ac246852a3fe3eb1442b5761405c710
4
- data.tar.gz: 8e7ad4fdab9353cdfb949f37c434ad27c85962c8
3
+ metadata.gz: 4dbff3dda7c98f1198de9dc53b46c1dd4a85e007
4
+ data.tar.gz: 204b0ccdbf19b4209f9cba200784ffc7c69b1dd5
5
5
  SHA512:
6
- metadata.gz: aed10d084a54338acea02b8814eda2d3f66a11f697b28de367ea401a62e5c61a8f2f691507af0abd7d1b9105744500797aa5bbcbf5581be0156d72e51cc2c717
7
- data.tar.gz: 0d1a0a14bfdbf99210825689beee67beb95f11f0f0d9358b741d4a5bf346edd9d155b0aa1f6c8ec029eddc0b6480646c5c006d8eec71367c37d3920bf260158f
6
+ metadata.gz: 1a85b297424cd0f900fe20de8c3a2ac0b816350d210ba319352a9fecca4a35f5031a2a1d0f6e6bb408f0b67a5e367e71bd36b8e8895c70b9a5e98179029aa19e
7
+ data.tar.gz: 92996a744e84b37b6a84a9f34048a464ac6edfad92abec2cea031e0f42f824c66268071dfe688d8a541c1d5e1fab04abe81136d6be33b63ac327d693cdd4cbec
data/README.md CHANGED
@@ -6,3 +6,32 @@ DevOps toolkit and Chef cookbook generator for Amazon Web Services based on [Sta
6
6
 
7
7
  ./bin/awskit gen toolkit --name mytoolkit
8
8
  ./bin/awskit gen cookbook --name mycookbook
9
+
10
+ ## Plugins
11
+
12
+ The generated toolkit supports a plugin style architecture that makes it easy to add new commands to the CLI.
13
+
14
+ To create a new command named "mycommand":
15
+
16
+ 1. Create directory %TOOLKIT_HOME%/lib/%TOOLKIT_NAME%/mycommand
17
+ 2. Create cli.rb with the following content
18
+
19
+ ```ruby
20
+ module MyToolkit::Mycommand
21
+
22
+ class Cli < Stackit::BaseCli
23
+
24
+ def initialize(*args)
25
+ super(*args)
26
+ end
27
+
28
+ def self.initialize_cli
29
+ Thor.desc "mycommand", "Runs mycommand"
30
+ Thor.subcommand "mycommand", self
31
+ end
32
+
33
+ end
34
+ end
35
+ ```
36
+
37
+ Now when the help command is run, "mycommand" is in the list of supported commands.
@@ -94,7 +94,7 @@ module Awskit::Gen::Cookbook
94
94
  FileUtils.cp(static_file('Thorfile'), "#{output_path}/Thorfile")
95
95
  FileUtils.cp(static_file('.gitignore'), "#{output_path}/.gitignore")
96
96
  FileUtils.cp(static_file('test/integration/default/serverspec/spec_helper.rb'), "#{output_path}/test/integration/default/serverspec/spec_helper.rb")
97
- FileUtils.cp(static_file('test/integration/default/serverspec/localhost/common_spec.rb'), "#{output_path}/test/integration/default/serverspec/localhost/common_spec.rb")
97
+ FileUtils.cp(static_file('test/integration/default/serverspec/localhost/default_spec.rb'), "#{output_path}/test/integration/default/serverspec/localhost/default_spec.rb")
98
98
  end
99
99
 
100
100
  def static_file(file)
@@ -9,7 +9,7 @@ module Awskit::Gen::Toolkit
9
9
 
10
10
  def initialize(options)
11
11
  self.options = options
12
- self.output_path = options[:path] || "./#{toolkit_name}"
12
+ self.output_path = "#{options[:path]}./#{toolkit_name}" || "./#{toolkit_name}"
13
13
  end
14
14
 
15
15
  def gen
@@ -1,3 +1,3 @@
1
1
  module Awskit
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awskit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremy Hahn
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-06-11 00:00:00.000000000 Z
11
+ date: 2016-07-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler