xfabricator 1.0.0 → 1.0.1

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: 322079b7d1a85c7ba769423c3ff5c12599a10a96
4
- data.tar.gz: 20318c1f5fab4b69061d3350898d8aba4314aa6d
3
+ metadata.gz: ba35ba380ab4c6735093f867d3ce107212f18b76
4
+ data.tar.gz: e14183712633b0fb740e164b4c5acebc8ea25f99
5
5
  SHA512:
6
- metadata.gz: 662d9432e58fc435fe18618d01604299e8336b9f66256e3b1e34fe9161bffc2b934aaaa1b2434b888024c22eba302df22b2426f9babc14bf50be0840c8500807
7
- data.tar.gz: 21b5944af780542391faf214450cf0a20fbe8590bb68f68c66656f492f4c4f213c814cf7425c3a65b099d4fd2c6a11ab82867fe90775ff48141b1701a10a1092
6
+ metadata.gz: 4b8c31ec9f20f75d26f38831ade4abe407f651ca3de109e4e8f7c874bbcba0de1e131e2bb0d0c8c62aefa637079f92c433f201bd80854e09130b70610ba2ad91
7
+ data.tar.gz: fa90829afa3126069b0872ee913e5211291b291b33f78789aaee44c16b3f85451f786c81f2633787442c423d09d463988edf3622ba6350471cc0d362455019ee
data/README.md CHANGED
@@ -1,7 +1,8 @@
1
1
  # xfabricator
2
2
 
3
- Generate files from mustache templates and add them directly to an xcode projects.
4
- * Generated files can be added to specific targets, groups and paths
3
+ Is a command line tool that generates files from mustache templates and add them directly to an xcode project.
4
+
5
+ * Generated files can be added to specific targets, groups
5
6
  * Generated files can be added to groups automatically based on the path
6
7
 
7
8
  ## Installation
@@ -60,7 +61,9 @@ TemplateDefinition.create_definition lambda { |template_definition|
60
61
  #Generated file names can include any project or template variable
61
62
  template_files = [
62
63
  TemplateFileDefinition.new("ExampleTemplate.h", '{{some_variable}}Widget.h'),
63
- TemplateFileDefinition.new("ExampleTemplate.m", '{{some_variable}}Widget.m')
64
+ TemplateFileDefinition.new("ExampleTemplate.m", '{{some_variable}}Widget.m'),
65
+ #optionally specify a sub path relative to the group
66
+ TemplateFileDefinition.new("example.txt", '{{another_variable}}Example.txt', 'a/deep/folder/path')
64
67
  ]
65
68
 
66
69
  template_definition[:template_files] = template_files
@@ -78,12 +81,34 @@ prompts defined in the template definition.
78
81
 
79
82
  ### Command line tool
80
83
 
84
+ The following add files fabricated by the Example template to the group represented by the present working directory
85
+ Fabricated files will be added to the default target specified in your .xfabricate file
86
+ ```sh
87
+ > cd a/sub/path/in/your/project/dir
88
+ > xfabricate -t Example
89
+ ```
90
+
91
+ The following add files fabricated by the Example template to the group represented by the present working directory
92
+ Fabricated files will be added to the default target specified in your .xfabricate file
93
+ ```sh
94
+ > cd /your/project/directory
95
+ > xfabricate -t Example -p a/sub/path/in/your/project/dir
96
+ ```
97
+
98
+ The following add files fabricated by the Example template to the group matching the name TestGroup
99
+ Fabricated files will be added to the default target specified in your .xfabricate file
100
+ ```sh
101
+ > cd /your/project/directory
102
+ > xfabricate -t Example -g TestGroup
103
+ ```
104
+
105
+
81
106
  ```
82
107
  Usage: xfabricate [options]
83
108
  -t, --template=template_name specify template to fabricate
84
109
  -a, --target=target_name specify target to add created files
85
110
  -g, --group=group_name specify group to add created files
86
- -p, --path=path_name specify path to generate created files
111
+ -p, --path=path_name specify search path to find the current group
87
112
  ```
88
113
 
89
114
  ## Development
data/bin/xfabricate CHANGED
@@ -96,7 +96,7 @@ OptionParser.new do |opts|
96
96
  end
97
97
 
98
98
  opts.on("-p path_name", "--path=path_name", "specify search path to find the current group") do |path|
99
- options[:path] = path
99
+ options[:path] = Pathname.new(path).expand_path
100
100
  end
101
101
 
102
102
  end.parse!
@@ -1,3 +1,3 @@
1
1
  module Xfabricator
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xfabricator
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nicholas Cross