api_gen_helper 0.1.4 → 0.1.5
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 +4 -4
- data/lib/api_gen_helper/group_generator.rb +9 -6
- data/lib/api_gen_helper/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4fff0bf46953864138e3e885d90077debcdaf440
|
4
|
+
data.tar.gz: '090866381df7cee1a0beb3ab6c84996d466473e1'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cdd8e0e0246ba189e7ed3caf23269741df9d86627a3fee7b4d8634947f51cf7cc5e1e5558994076114b88013cb3c26a34f48e8d3b17c58463d5dc05d43882f0b
|
7
|
+
data.tar.gz: 12c30a48ffc0d3ab094defee4169eee66586891b48edd64f01b62524cfe9f526826d0435507ea03450fb740fdad979753a71aac3b38e4ae494e76f9bd6d07d8a
|
@@ -11,9 +11,9 @@ module ApiGenHelper
|
|
11
11
|
|
12
12
|
clear_group(project, [target_name], group_path)
|
13
13
|
|
14
|
-
group = retrieve_group_or_create_if_needed(group_path,
|
14
|
+
group = retrieve_group_or_create_if_needed(group_path, nil, nil, project, true)
|
15
15
|
|
16
|
-
prepare_main_group(group, group_path)
|
16
|
+
prepare_main_group(group, group_path, project)
|
17
17
|
|
18
18
|
project.targets.each do |target|
|
19
19
|
if target.name == target_name
|
@@ -41,19 +41,22 @@ module ApiGenHelper
|
|
41
41
|
# Recursively fills the group with files and groups
|
42
42
|
# @param group [PBXGroup] group to fill out
|
43
43
|
# @param directory [String] path directory when search files and folders
|
44
|
-
def prepare_main_group(group, directory)
|
44
|
+
def prepare_main_group(group, directory, project)
|
45
|
+
|
45
46
|
Dir.entries(directory).each do |file_name|
|
46
47
|
next if file_name =~ /^\./
|
48
|
+
|
47
49
|
if File.file? File.join(directory, file_name)
|
48
50
|
file_path = File.join(directory, file_name)
|
49
|
-
xcode_file_reference = group.
|
51
|
+
xcode_file_reference = group.new_file(File.absolute_path(file_path))
|
50
52
|
end
|
51
53
|
|
52
54
|
if File.directory? File.join(directory, file_name)
|
53
55
|
sub_dir = File.join(directory, file_name)
|
54
|
-
|
55
|
-
prepare_main_group(
|
56
|
+
new_group = retrieve_group_or_create_if_needed(sub_dir, nil, nil, project, true)
|
57
|
+
prepare_main_group(new_group, sub_dir, project)
|
56
58
|
end
|
59
|
+
|
57
60
|
end
|
58
61
|
end
|
59
62
|
|