ovaltine 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.travis.yml +17 -0
- data/CHANGELOG.md +3 -0
- data/LICENSE +22 -0
- data/README.md +15 -0
- data/Rakefile +5 -0
- data/TODO.md +6 -0
- data/bin/ovaltine +54 -0
- data/features/fixtures/Sample/Sample/Base.lproj/Main.storyboard +125 -0
- data/features/fixtures/Sample/Sample/DMMAppDelegate.h +15 -0
- data/features/fixtures/Sample/Sample/DMMAppDelegate.m +46 -0
- data/features/fixtures/Sample/Sample/DMMViewController.h +13 -0
- data/features/fixtures/Sample/Sample/DMMViewController.m +29 -0
- data/features/fixtures/Sample/Sample/Images.xcassets/AppIcon.appiconset/Contents.json +23 -0
- data/features/fixtures/Sample/Sample/Images.xcassets/LaunchImage.launchimage/Contents.json +23 -0
- data/features/fixtures/Sample/Sample/Sample-Info.plist +40 -0
- data/features/fixtures/Sample/Sample/Sample-Prefix.pch +16 -0
- data/features/fixtures/Sample/Sample/en.lproj/InfoPlist.strings +2 -0
- data/features/fixtures/Sample/Sample/main.m +18 -0
- data/features/fixtures/Sample/Sample.xcodeproj/project.pbxproj +472 -0
- data/features/fixtures/Sample/Sample.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
- data/features/fixtures/Sample/SampleTests/SampleTests-Info.plist +22 -0
- data/features/fixtures/Sample/SampleTests/SampleTests.m +34 -0
- data/features/fixtures/Sample/SampleTests/en.lproj/InfoPlist.strings +2 -0
- data/lib/ovaltine/objc/storyboard_formatter.rb +139 -0
- data/lib/ovaltine/objc/storyboard_templates.rb +59 -0
- data/lib/ovaltine/storyboard.rb +51 -0
- data/lib/ovaltine/version.rb +3 -0
- data/lib/ovaltine.rb +51 -0
- data/ovaltine.gemspec +28 -0
- data/specs/storyboard_formatter_spec.rb +29 -0
- data/specs/storyboard_spec.rb +36 -0
- metadata +134 -0
@@ -0,0 +1,472 @@
|
|
1
|
+
// !$*UTF8*$!
|
2
|
+
{
|
3
|
+
archiveVersion = 1;
|
4
|
+
classes = {
|
5
|
+
};
|
6
|
+
objectVersion = 46;
|
7
|
+
objects = {
|
8
|
+
|
9
|
+
/* Begin PBXBuildFile section */
|
10
|
+
8AB8CD2F198D6B6400CEA0CD /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8AB8CD2E198D6B6400CEA0CD /* Foundation.framework */; };
|
11
|
+
8AB8CD31198D6B6400CEA0CD /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8AB8CD30198D6B6400CEA0CD /* CoreGraphics.framework */; };
|
12
|
+
8AB8CD33198D6B6400CEA0CD /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8AB8CD32198D6B6400CEA0CD /* UIKit.framework */; };
|
13
|
+
8AB8CD39198D6B6400CEA0CD /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 8AB8CD37198D6B6400CEA0CD /* InfoPlist.strings */; };
|
14
|
+
8AB8CD3B198D6B6400CEA0CD /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 8AB8CD3A198D6B6400CEA0CD /* main.m */; };
|
15
|
+
8AB8CD3F198D6B6400CEA0CD /* DMMAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 8AB8CD3E198D6B6400CEA0CD /* DMMAppDelegate.m */; };
|
16
|
+
8AB8CD42198D6B6400CEA0CD /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 8AB8CD40198D6B6400CEA0CD /* Main.storyboard */; };
|
17
|
+
8AB8CD45198D6B6400CEA0CD /* DMMViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 8AB8CD44198D6B6400CEA0CD /* DMMViewController.m */; };
|
18
|
+
8AB8CD47198D6B6400CEA0CD /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 8AB8CD46198D6B6400CEA0CD /* Images.xcassets */; };
|
19
|
+
8AB8CD4E198D6B6500CEA0CD /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8AB8CD4D198D6B6500CEA0CD /* XCTest.framework */; };
|
20
|
+
8AB8CD4F198D6B6500CEA0CD /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8AB8CD2E198D6B6400CEA0CD /* Foundation.framework */; };
|
21
|
+
8AB8CD50198D6B6500CEA0CD /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8AB8CD32198D6B6400CEA0CD /* UIKit.framework */; };
|
22
|
+
8AB8CD58198D6B6500CEA0CD /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 8AB8CD56198D6B6500CEA0CD /* InfoPlist.strings */; };
|
23
|
+
8AB8CD5A198D6B6500CEA0CD /* SampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 8AB8CD59198D6B6500CEA0CD /* SampleTests.m */; };
|
24
|
+
/* End PBXBuildFile section */
|
25
|
+
|
26
|
+
/* Begin PBXContainerItemProxy section */
|
27
|
+
8AB8CD51198D6B6500CEA0CD /* PBXContainerItemProxy */ = {
|
28
|
+
isa = PBXContainerItemProxy;
|
29
|
+
containerPortal = 8AB8CD23198D6B6400CEA0CD /* Project object */;
|
30
|
+
proxyType = 1;
|
31
|
+
remoteGlobalIDString = 8AB8CD2A198D6B6400CEA0CD;
|
32
|
+
remoteInfo = Sample;
|
33
|
+
};
|
34
|
+
/* End PBXContainerItemProxy section */
|
35
|
+
|
36
|
+
/* Begin PBXFileReference section */
|
37
|
+
8AB8CD2B198D6B6400CEA0CD /* Sample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Sample.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
38
|
+
8AB8CD2E198D6B6400CEA0CD /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
|
39
|
+
8AB8CD30198D6B6400CEA0CD /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
|
40
|
+
8AB8CD32198D6B6400CEA0CD /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
|
41
|
+
8AB8CD36198D6B6400CEA0CD /* Sample-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Sample-Info.plist"; sourceTree = "<group>"; };
|
42
|
+
8AB8CD38198D6B6400CEA0CD /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
43
|
+
8AB8CD3A198D6B6400CEA0CD /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
|
44
|
+
8AB8CD3C198D6B6400CEA0CD /* Sample-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Sample-Prefix.pch"; sourceTree = "<group>"; };
|
45
|
+
8AB8CD3D198D6B6400CEA0CD /* DMMAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DMMAppDelegate.h; sourceTree = "<group>"; };
|
46
|
+
8AB8CD3E198D6B6400CEA0CD /* DMMAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DMMAppDelegate.m; sourceTree = "<group>"; };
|
47
|
+
8AB8CD41198D6B6400CEA0CD /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
|
48
|
+
8AB8CD43198D6B6400CEA0CD /* DMMViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DMMViewController.h; sourceTree = "<group>"; };
|
49
|
+
8AB8CD44198D6B6400CEA0CD /* DMMViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DMMViewController.m; sourceTree = "<group>"; };
|
50
|
+
8AB8CD46198D6B6400CEA0CD /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = "<group>"; };
|
51
|
+
8AB8CD4C198D6B6500CEA0CD /* SampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = SampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
|
52
|
+
8AB8CD4D198D6B6500CEA0CD /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; };
|
53
|
+
8AB8CD55198D6B6500CEA0CD /* SampleTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "SampleTests-Info.plist"; sourceTree = "<group>"; };
|
54
|
+
8AB8CD57198D6B6500CEA0CD /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
55
|
+
8AB8CD59198D6B6500CEA0CD /* SampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SampleTests.m; sourceTree = "<group>"; };
|
56
|
+
/* End PBXFileReference section */
|
57
|
+
|
58
|
+
/* Begin PBXFrameworksBuildPhase section */
|
59
|
+
8AB8CD28198D6B6400CEA0CD /* Frameworks */ = {
|
60
|
+
isa = PBXFrameworksBuildPhase;
|
61
|
+
buildActionMask = 2147483647;
|
62
|
+
files = (
|
63
|
+
8AB8CD31198D6B6400CEA0CD /* CoreGraphics.framework in Frameworks */,
|
64
|
+
8AB8CD33198D6B6400CEA0CD /* UIKit.framework in Frameworks */,
|
65
|
+
8AB8CD2F198D6B6400CEA0CD /* Foundation.framework in Frameworks */,
|
66
|
+
);
|
67
|
+
runOnlyForDeploymentPostprocessing = 0;
|
68
|
+
};
|
69
|
+
8AB8CD49198D6B6500CEA0CD /* Frameworks */ = {
|
70
|
+
isa = PBXFrameworksBuildPhase;
|
71
|
+
buildActionMask = 2147483647;
|
72
|
+
files = (
|
73
|
+
8AB8CD4E198D6B6500CEA0CD /* XCTest.framework in Frameworks */,
|
74
|
+
8AB8CD50198D6B6500CEA0CD /* UIKit.framework in Frameworks */,
|
75
|
+
8AB8CD4F198D6B6500CEA0CD /* Foundation.framework in Frameworks */,
|
76
|
+
);
|
77
|
+
runOnlyForDeploymentPostprocessing = 0;
|
78
|
+
};
|
79
|
+
/* End PBXFrameworksBuildPhase section */
|
80
|
+
|
81
|
+
/* Begin PBXGroup section */
|
82
|
+
8AB8CD22198D6B6400CEA0CD = {
|
83
|
+
isa = PBXGroup;
|
84
|
+
children = (
|
85
|
+
8AB8CD34198D6B6400CEA0CD /* Sample */,
|
86
|
+
8AB8CD53198D6B6500CEA0CD /* SampleTests */,
|
87
|
+
8AB8CD2D198D6B6400CEA0CD /* Frameworks */,
|
88
|
+
8AB8CD2C198D6B6400CEA0CD /* Products */,
|
89
|
+
);
|
90
|
+
sourceTree = "<group>";
|
91
|
+
};
|
92
|
+
8AB8CD2C198D6B6400CEA0CD /* Products */ = {
|
93
|
+
isa = PBXGroup;
|
94
|
+
children = (
|
95
|
+
8AB8CD2B198D6B6400CEA0CD /* Sample.app */,
|
96
|
+
8AB8CD4C198D6B6500CEA0CD /* SampleTests.xctest */,
|
97
|
+
);
|
98
|
+
name = Products;
|
99
|
+
sourceTree = "<group>";
|
100
|
+
};
|
101
|
+
8AB8CD2D198D6B6400CEA0CD /* Frameworks */ = {
|
102
|
+
isa = PBXGroup;
|
103
|
+
children = (
|
104
|
+
8AB8CD2E198D6B6400CEA0CD /* Foundation.framework */,
|
105
|
+
8AB8CD30198D6B6400CEA0CD /* CoreGraphics.framework */,
|
106
|
+
8AB8CD32198D6B6400CEA0CD /* UIKit.framework */,
|
107
|
+
8AB8CD4D198D6B6500CEA0CD /* XCTest.framework */,
|
108
|
+
);
|
109
|
+
name = Frameworks;
|
110
|
+
sourceTree = "<group>";
|
111
|
+
};
|
112
|
+
8AB8CD34198D6B6400CEA0CD /* Sample */ = {
|
113
|
+
isa = PBXGroup;
|
114
|
+
children = (
|
115
|
+
8AB8CD3D198D6B6400CEA0CD /* DMMAppDelegate.h */,
|
116
|
+
8AB8CD3E198D6B6400CEA0CD /* DMMAppDelegate.m */,
|
117
|
+
8AB8CD40198D6B6400CEA0CD /* Main.storyboard */,
|
118
|
+
8AB8CD43198D6B6400CEA0CD /* DMMViewController.h */,
|
119
|
+
8AB8CD44198D6B6400CEA0CD /* DMMViewController.m */,
|
120
|
+
8AB8CD46198D6B6400CEA0CD /* Images.xcassets */,
|
121
|
+
8AB8CD35198D6B6400CEA0CD /* Supporting Files */,
|
122
|
+
);
|
123
|
+
path = Sample;
|
124
|
+
sourceTree = "<group>";
|
125
|
+
};
|
126
|
+
8AB8CD35198D6B6400CEA0CD /* Supporting Files */ = {
|
127
|
+
isa = PBXGroup;
|
128
|
+
children = (
|
129
|
+
8AB8CD36198D6B6400CEA0CD /* Sample-Info.plist */,
|
130
|
+
8AB8CD37198D6B6400CEA0CD /* InfoPlist.strings */,
|
131
|
+
8AB8CD3A198D6B6400CEA0CD /* main.m */,
|
132
|
+
8AB8CD3C198D6B6400CEA0CD /* Sample-Prefix.pch */,
|
133
|
+
);
|
134
|
+
name = "Supporting Files";
|
135
|
+
sourceTree = "<group>";
|
136
|
+
};
|
137
|
+
8AB8CD53198D6B6500CEA0CD /* SampleTests */ = {
|
138
|
+
isa = PBXGroup;
|
139
|
+
children = (
|
140
|
+
8AB8CD59198D6B6500CEA0CD /* SampleTests.m */,
|
141
|
+
8AB8CD54198D6B6500CEA0CD /* Supporting Files */,
|
142
|
+
);
|
143
|
+
path = SampleTests;
|
144
|
+
sourceTree = "<group>";
|
145
|
+
};
|
146
|
+
8AB8CD54198D6B6500CEA0CD /* Supporting Files */ = {
|
147
|
+
isa = PBXGroup;
|
148
|
+
children = (
|
149
|
+
8AB8CD55198D6B6500CEA0CD /* SampleTests-Info.plist */,
|
150
|
+
8AB8CD56198D6B6500CEA0CD /* InfoPlist.strings */,
|
151
|
+
);
|
152
|
+
name = "Supporting Files";
|
153
|
+
sourceTree = "<group>";
|
154
|
+
};
|
155
|
+
/* End PBXGroup section */
|
156
|
+
|
157
|
+
/* Begin PBXNativeTarget section */
|
158
|
+
8AB8CD2A198D6B6400CEA0CD /* Sample */ = {
|
159
|
+
isa = PBXNativeTarget;
|
160
|
+
buildConfigurationList = 8AB8CD5D198D6B6500CEA0CD /* Build configuration list for PBXNativeTarget "Sample" */;
|
161
|
+
buildPhases = (
|
162
|
+
8AB8CD27198D6B6400CEA0CD /* Sources */,
|
163
|
+
8AB8CD28198D6B6400CEA0CD /* Frameworks */,
|
164
|
+
8AB8CD29198D6B6400CEA0CD /* Resources */,
|
165
|
+
);
|
166
|
+
buildRules = (
|
167
|
+
);
|
168
|
+
dependencies = (
|
169
|
+
);
|
170
|
+
name = Sample;
|
171
|
+
productName = Sample;
|
172
|
+
productReference = 8AB8CD2B198D6B6400CEA0CD /* Sample.app */;
|
173
|
+
productType = "com.apple.product-type.application";
|
174
|
+
};
|
175
|
+
8AB8CD4B198D6B6500CEA0CD /* SampleTests */ = {
|
176
|
+
isa = PBXNativeTarget;
|
177
|
+
buildConfigurationList = 8AB8CD60198D6B6500CEA0CD /* Build configuration list for PBXNativeTarget "SampleTests" */;
|
178
|
+
buildPhases = (
|
179
|
+
8AB8CD48198D6B6500CEA0CD /* Sources */,
|
180
|
+
8AB8CD49198D6B6500CEA0CD /* Frameworks */,
|
181
|
+
8AB8CD4A198D6B6500CEA0CD /* Resources */,
|
182
|
+
);
|
183
|
+
buildRules = (
|
184
|
+
);
|
185
|
+
dependencies = (
|
186
|
+
8AB8CD52198D6B6500CEA0CD /* PBXTargetDependency */,
|
187
|
+
);
|
188
|
+
name = SampleTests;
|
189
|
+
productName = SampleTests;
|
190
|
+
productReference = 8AB8CD4C198D6B6500CEA0CD /* SampleTests.xctest */;
|
191
|
+
productType = "com.apple.product-type.bundle.unit-test";
|
192
|
+
};
|
193
|
+
/* End PBXNativeTarget section */
|
194
|
+
|
195
|
+
/* Begin PBXProject section */
|
196
|
+
8AB8CD23198D6B6400CEA0CD /* Project object */ = {
|
197
|
+
isa = PBXProject;
|
198
|
+
attributes = {
|
199
|
+
CLASSPREFIX = DMM;
|
200
|
+
LastUpgradeCheck = 0510;
|
201
|
+
ORGANIZATIONNAME = "Delisa Mason";
|
202
|
+
TargetAttributes = {
|
203
|
+
8AB8CD4B198D6B6500CEA0CD = {
|
204
|
+
TestTargetID = 8AB8CD2A198D6B6400CEA0CD;
|
205
|
+
};
|
206
|
+
};
|
207
|
+
};
|
208
|
+
buildConfigurationList = 8AB8CD26198D6B6400CEA0CD /* Build configuration list for PBXProject "Sample" */;
|
209
|
+
compatibilityVersion = "Xcode 3.2";
|
210
|
+
developmentRegion = English;
|
211
|
+
hasScannedForEncodings = 0;
|
212
|
+
knownRegions = (
|
213
|
+
en,
|
214
|
+
Base,
|
215
|
+
);
|
216
|
+
mainGroup = 8AB8CD22198D6B6400CEA0CD;
|
217
|
+
productRefGroup = 8AB8CD2C198D6B6400CEA0CD /* Products */;
|
218
|
+
projectDirPath = "";
|
219
|
+
projectRoot = "";
|
220
|
+
targets = (
|
221
|
+
8AB8CD2A198D6B6400CEA0CD /* Sample */,
|
222
|
+
8AB8CD4B198D6B6500CEA0CD /* SampleTests */,
|
223
|
+
);
|
224
|
+
};
|
225
|
+
/* End PBXProject section */
|
226
|
+
|
227
|
+
/* Begin PBXResourcesBuildPhase section */
|
228
|
+
8AB8CD29198D6B6400CEA0CD /* Resources */ = {
|
229
|
+
isa = PBXResourcesBuildPhase;
|
230
|
+
buildActionMask = 2147483647;
|
231
|
+
files = (
|
232
|
+
8AB8CD47198D6B6400CEA0CD /* Images.xcassets in Resources */,
|
233
|
+
8AB8CD39198D6B6400CEA0CD /* InfoPlist.strings in Resources */,
|
234
|
+
8AB8CD42198D6B6400CEA0CD /* Main.storyboard in Resources */,
|
235
|
+
);
|
236
|
+
runOnlyForDeploymentPostprocessing = 0;
|
237
|
+
};
|
238
|
+
8AB8CD4A198D6B6500CEA0CD /* Resources */ = {
|
239
|
+
isa = PBXResourcesBuildPhase;
|
240
|
+
buildActionMask = 2147483647;
|
241
|
+
files = (
|
242
|
+
8AB8CD58198D6B6500CEA0CD /* InfoPlist.strings in Resources */,
|
243
|
+
);
|
244
|
+
runOnlyForDeploymentPostprocessing = 0;
|
245
|
+
};
|
246
|
+
/* End PBXResourcesBuildPhase section */
|
247
|
+
|
248
|
+
/* Begin PBXSourcesBuildPhase section */
|
249
|
+
8AB8CD27198D6B6400CEA0CD /* Sources */ = {
|
250
|
+
isa = PBXSourcesBuildPhase;
|
251
|
+
buildActionMask = 2147483647;
|
252
|
+
files = (
|
253
|
+
8AB8CD45198D6B6400CEA0CD /* DMMViewController.m in Sources */,
|
254
|
+
8AB8CD3B198D6B6400CEA0CD /* main.m in Sources */,
|
255
|
+
8AB8CD3F198D6B6400CEA0CD /* DMMAppDelegate.m in Sources */,
|
256
|
+
);
|
257
|
+
runOnlyForDeploymentPostprocessing = 0;
|
258
|
+
};
|
259
|
+
8AB8CD48198D6B6500CEA0CD /* Sources */ = {
|
260
|
+
isa = PBXSourcesBuildPhase;
|
261
|
+
buildActionMask = 2147483647;
|
262
|
+
files = (
|
263
|
+
8AB8CD5A198D6B6500CEA0CD /* SampleTests.m in Sources */,
|
264
|
+
);
|
265
|
+
runOnlyForDeploymentPostprocessing = 0;
|
266
|
+
};
|
267
|
+
/* End PBXSourcesBuildPhase section */
|
268
|
+
|
269
|
+
/* Begin PBXTargetDependency section */
|
270
|
+
8AB8CD52198D6B6500CEA0CD /* PBXTargetDependency */ = {
|
271
|
+
isa = PBXTargetDependency;
|
272
|
+
target = 8AB8CD2A198D6B6400CEA0CD /* Sample */;
|
273
|
+
targetProxy = 8AB8CD51198D6B6500CEA0CD /* PBXContainerItemProxy */;
|
274
|
+
};
|
275
|
+
/* End PBXTargetDependency section */
|
276
|
+
|
277
|
+
/* Begin PBXVariantGroup section */
|
278
|
+
8AB8CD37198D6B6400CEA0CD /* InfoPlist.strings */ = {
|
279
|
+
isa = PBXVariantGroup;
|
280
|
+
children = (
|
281
|
+
8AB8CD38198D6B6400CEA0CD /* en */,
|
282
|
+
);
|
283
|
+
name = InfoPlist.strings;
|
284
|
+
sourceTree = "<group>";
|
285
|
+
};
|
286
|
+
8AB8CD40198D6B6400CEA0CD /* Main.storyboard */ = {
|
287
|
+
isa = PBXVariantGroup;
|
288
|
+
children = (
|
289
|
+
8AB8CD41198D6B6400CEA0CD /* Base */,
|
290
|
+
);
|
291
|
+
name = Main.storyboard;
|
292
|
+
sourceTree = "<group>";
|
293
|
+
};
|
294
|
+
8AB8CD56198D6B6500CEA0CD /* InfoPlist.strings */ = {
|
295
|
+
isa = PBXVariantGroup;
|
296
|
+
children = (
|
297
|
+
8AB8CD57198D6B6500CEA0CD /* en */,
|
298
|
+
);
|
299
|
+
name = InfoPlist.strings;
|
300
|
+
sourceTree = "<group>";
|
301
|
+
};
|
302
|
+
/* End PBXVariantGroup section */
|
303
|
+
|
304
|
+
/* Begin XCBuildConfiguration section */
|
305
|
+
8AB8CD5B198D6B6500CEA0CD /* Debug */ = {
|
306
|
+
isa = XCBuildConfiguration;
|
307
|
+
buildSettings = {
|
308
|
+
ALWAYS_SEARCH_USER_PATHS = NO;
|
309
|
+
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
310
|
+
CLANG_CXX_LIBRARY = "libc++";
|
311
|
+
CLANG_ENABLE_MODULES = YES;
|
312
|
+
CLANG_ENABLE_OBJC_ARC = YES;
|
313
|
+
CLANG_WARN_BOOL_CONVERSION = YES;
|
314
|
+
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
315
|
+
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
316
|
+
CLANG_WARN_EMPTY_BODY = YES;
|
317
|
+
CLANG_WARN_ENUM_CONVERSION = YES;
|
318
|
+
CLANG_WARN_INT_CONVERSION = YES;
|
319
|
+
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
320
|
+
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
321
|
+
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
322
|
+
COPY_PHASE_STRIP = NO;
|
323
|
+
GCC_C_LANGUAGE_STANDARD = gnu99;
|
324
|
+
GCC_DYNAMIC_NO_PIC = NO;
|
325
|
+
GCC_OPTIMIZATION_LEVEL = 0;
|
326
|
+
GCC_PREPROCESSOR_DEFINITIONS = (
|
327
|
+
"DEBUG=1",
|
328
|
+
"$(inherited)",
|
329
|
+
);
|
330
|
+
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
|
331
|
+
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
332
|
+
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
333
|
+
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
334
|
+
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
335
|
+
GCC_WARN_UNUSED_FUNCTION = YES;
|
336
|
+
GCC_WARN_UNUSED_VARIABLE = YES;
|
337
|
+
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
|
338
|
+
ONLY_ACTIVE_ARCH = YES;
|
339
|
+
SDKROOT = iphoneos;
|
340
|
+
};
|
341
|
+
name = Debug;
|
342
|
+
};
|
343
|
+
8AB8CD5C198D6B6500CEA0CD /* Release */ = {
|
344
|
+
isa = XCBuildConfiguration;
|
345
|
+
buildSettings = {
|
346
|
+
ALWAYS_SEARCH_USER_PATHS = NO;
|
347
|
+
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
348
|
+
CLANG_CXX_LIBRARY = "libc++";
|
349
|
+
CLANG_ENABLE_MODULES = YES;
|
350
|
+
CLANG_ENABLE_OBJC_ARC = YES;
|
351
|
+
CLANG_WARN_BOOL_CONVERSION = YES;
|
352
|
+
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
353
|
+
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
354
|
+
CLANG_WARN_EMPTY_BODY = YES;
|
355
|
+
CLANG_WARN_ENUM_CONVERSION = YES;
|
356
|
+
CLANG_WARN_INT_CONVERSION = YES;
|
357
|
+
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
358
|
+
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
359
|
+
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
360
|
+
COPY_PHASE_STRIP = YES;
|
361
|
+
ENABLE_NS_ASSERTIONS = NO;
|
362
|
+
GCC_C_LANGUAGE_STANDARD = gnu99;
|
363
|
+
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
364
|
+
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
365
|
+
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
366
|
+
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
367
|
+
GCC_WARN_UNUSED_FUNCTION = YES;
|
368
|
+
GCC_WARN_UNUSED_VARIABLE = YES;
|
369
|
+
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
|
370
|
+
SDKROOT = iphoneos;
|
371
|
+
VALIDATE_PRODUCT = YES;
|
372
|
+
};
|
373
|
+
name = Release;
|
374
|
+
};
|
375
|
+
8AB8CD5E198D6B6500CEA0CD /* Debug */ = {
|
376
|
+
isa = XCBuildConfiguration;
|
377
|
+
buildSettings = {
|
378
|
+
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
379
|
+
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
|
380
|
+
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
381
|
+
GCC_PREFIX_HEADER = "Sample/Sample-Prefix.pch";
|
382
|
+
INFOPLIST_FILE = "Sample/Sample-Info.plist";
|
383
|
+
PRODUCT_NAME = "$(TARGET_NAME)";
|
384
|
+
WRAPPER_EXTENSION = app;
|
385
|
+
};
|
386
|
+
name = Debug;
|
387
|
+
};
|
388
|
+
8AB8CD5F198D6B6500CEA0CD /* Release */ = {
|
389
|
+
isa = XCBuildConfiguration;
|
390
|
+
buildSettings = {
|
391
|
+
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
392
|
+
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
|
393
|
+
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
394
|
+
GCC_PREFIX_HEADER = "Sample/Sample-Prefix.pch";
|
395
|
+
INFOPLIST_FILE = "Sample/Sample-Info.plist";
|
396
|
+
PRODUCT_NAME = "$(TARGET_NAME)";
|
397
|
+
WRAPPER_EXTENSION = app;
|
398
|
+
};
|
399
|
+
name = Release;
|
400
|
+
};
|
401
|
+
8AB8CD61198D6B6500CEA0CD /* Debug */ = {
|
402
|
+
isa = XCBuildConfiguration;
|
403
|
+
buildSettings = {
|
404
|
+
BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/Sample.app/Sample";
|
405
|
+
FRAMEWORK_SEARCH_PATHS = (
|
406
|
+
"$(SDKROOT)/Developer/Library/Frameworks",
|
407
|
+
"$(inherited)",
|
408
|
+
"$(DEVELOPER_FRAMEWORKS_DIR)",
|
409
|
+
);
|
410
|
+
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
411
|
+
GCC_PREFIX_HEADER = "Sample/Sample-Prefix.pch";
|
412
|
+
GCC_PREPROCESSOR_DEFINITIONS = (
|
413
|
+
"DEBUG=1",
|
414
|
+
"$(inherited)",
|
415
|
+
);
|
416
|
+
INFOPLIST_FILE = "SampleTests/SampleTests-Info.plist";
|
417
|
+
PRODUCT_NAME = "$(TARGET_NAME)";
|
418
|
+
TEST_HOST = "$(BUNDLE_LOADER)";
|
419
|
+
WRAPPER_EXTENSION = xctest;
|
420
|
+
};
|
421
|
+
name = Debug;
|
422
|
+
};
|
423
|
+
8AB8CD62198D6B6500CEA0CD /* Release */ = {
|
424
|
+
isa = XCBuildConfiguration;
|
425
|
+
buildSettings = {
|
426
|
+
BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/Sample.app/Sample";
|
427
|
+
FRAMEWORK_SEARCH_PATHS = (
|
428
|
+
"$(SDKROOT)/Developer/Library/Frameworks",
|
429
|
+
"$(inherited)",
|
430
|
+
"$(DEVELOPER_FRAMEWORKS_DIR)",
|
431
|
+
);
|
432
|
+
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
433
|
+
GCC_PREFIX_HEADER = "Sample/Sample-Prefix.pch";
|
434
|
+
INFOPLIST_FILE = "SampleTests/SampleTests-Info.plist";
|
435
|
+
PRODUCT_NAME = "$(TARGET_NAME)";
|
436
|
+
TEST_HOST = "$(BUNDLE_LOADER)";
|
437
|
+
WRAPPER_EXTENSION = xctest;
|
438
|
+
};
|
439
|
+
name = Release;
|
440
|
+
};
|
441
|
+
/* End XCBuildConfiguration section */
|
442
|
+
|
443
|
+
/* Begin XCConfigurationList section */
|
444
|
+
8AB8CD26198D6B6400CEA0CD /* Build configuration list for PBXProject "Sample" */ = {
|
445
|
+
isa = XCConfigurationList;
|
446
|
+
buildConfigurations = (
|
447
|
+
8AB8CD5B198D6B6500CEA0CD /* Debug */,
|
448
|
+
8AB8CD5C198D6B6500CEA0CD /* Release */,
|
449
|
+
);
|
450
|
+
defaultConfigurationIsVisible = 0;
|
451
|
+
defaultConfigurationName = Release;
|
452
|
+
};
|
453
|
+
8AB8CD5D198D6B6500CEA0CD /* Build configuration list for PBXNativeTarget "Sample" */ = {
|
454
|
+
isa = XCConfigurationList;
|
455
|
+
buildConfigurations = (
|
456
|
+
8AB8CD5E198D6B6500CEA0CD /* Debug */,
|
457
|
+
8AB8CD5F198D6B6500CEA0CD /* Release */,
|
458
|
+
);
|
459
|
+
defaultConfigurationIsVisible = 0;
|
460
|
+
};
|
461
|
+
8AB8CD60198D6B6500CEA0CD /* Build configuration list for PBXNativeTarget "SampleTests" */ = {
|
462
|
+
isa = XCConfigurationList;
|
463
|
+
buildConfigurations = (
|
464
|
+
8AB8CD61198D6B6500CEA0CD /* Debug */,
|
465
|
+
8AB8CD62198D6B6500CEA0CD /* Release */,
|
466
|
+
);
|
467
|
+
defaultConfigurationIsVisible = 0;
|
468
|
+
};
|
469
|
+
/* End XCConfigurationList section */
|
470
|
+
};
|
471
|
+
rootObject = 8AB8CD23198D6B6400CEA0CD /* Project object */;
|
472
|
+
}
|
@@ -0,0 +1,22 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
3
|
+
<plist version="1.0">
|
4
|
+
<dict>
|
5
|
+
<key>CFBundleDevelopmentRegion</key>
|
6
|
+
<string>en</string>
|
7
|
+
<key>CFBundleExecutable</key>
|
8
|
+
<string>${EXECUTABLE_NAME}</string>
|
9
|
+
<key>CFBundleIdentifier</key>
|
10
|
+
<string>me.delisa.${PRODUCT_NAME:rfc1034identifier}</string>
|
11
|
+
<key>CFBundleInfoDictionaryVersion</key>
|
12
|
+
<string>6.0</string>
|
13
|
+
<key>CFBundlePackageType</key>
|
14
|
+
<string>BNDL</string>
|
15
|
+
<key>CFBundleShortVersionString</key>
|
16
|
+
<string>1.0</string>
|
17
|
+
<key>CFBundleSignature</key>
|
18
|
+
<string>????</string>
|
19
|
+
<key>CFBundleVersion</key>
|
20
|
+
<string>1</string>
|
21
|
+
</dict>
|
22
|
+
</plist>
|
@@ -0,0 +1,34 @@
|
|
1
|
+
//
|
2
|
+
// SampleTests.m
|
3
|
+
// SampleTests
|
4
|
+
//
|
5
|
+
// Created by Delisa Mason on 8/2/14.
|
6
|
+
// Copyright (c) 2014 Delisa Mason. All rights reserved.
|
7
|
+
//
|
8
|
+
|
9
|
+
#import <XCTest/XCTest.h>
|
10
|
+
|
11
|
+
@interface SampleTests : XCTestCase
|
12
|
+
|
13
|
+
@end
|
14
|
+
|
15
|
+
@implementation SampleTests
|
16
|
+
|
17
|
+
- (void)setUp
|
18
|
+
{
|
19
|
+
[super setUp];
|
20
|
+
// Put setup code here. This method is called before the invocation of each test method in the class.
|
21
|
+
}
|
22
|
+
|
23
|
+
- (void)tearDown
|
24
|
+
{
|
25
|
+
// Put teardown code here. This method is called after the invocation of each test method in the class.
|
26
|
+
[super tearDown];
|
27
|
+
}
|
28
|
+
|
29
|
+
- (void)testExample
|
30
|
+
{
|
31
|
+
XCTFail(@"No implementation for \"%s\"", __PRETTY_FUNCTION__);
|
32
|
+
}
|
33
|
+
|
34
|
+
@end
|
@@ -0,0 +1,139 @@
|
|
1
|
+
|
2
|
+
module Ovaltine
|
3
|
+
class StoryboardFormatter
|
4
|
+
attr_reader :storyboard, :classname
|
5
|
+
|
6
|
+
CELL_REUSE_SECTION_TITLE='Cell Reuse Identifiers'
|
7
|
+
SEGUE_SECTION_TITLE='Segue Identifiers'
|
8
|
+
VIEW_CONTROLLER_SECTION_TITLE='View Controllers'
|
9
|
+
|
10
|
+
def initialize storyboard, prefix, output_path
|
11
|
+
scrubbed_name = storyboard.name.gsub(/\W/,'_')
|
12
|
+
@storyboard = storyboard
|
13
|
+
@prefix = prefix
|
14
|
+
@classname = "#{@prefix}#{scrubbed_name}Storyboard"
|
15
|
+
@header_path = File.join(File.expand_path(output_path), "#{classname}.h")
|
16
|
+
@impl_path = File.join(File.expand_path(output_path), "#{classname}.m")
|
17
|
+
end
|
18
|
+
|
19
|
+
def output_paths
|
20
|
+
[@header_path, @impl_path]
|
21
|
+
end
|
22
|
+
|
23
|
+
def write
|
24
|
+
File.open(@header_path, 'w') do |file|
|
25
|
+
file.puts generate_header
|
26
|
+
end
|
27
|
+
File.open(@impl_path, 'w') do |file|
|
28
|
+
file.puts generate_implementation
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
private
|
33
|
+
|
34
|
+
def generate_header
|
35
|
+
StoryboardTemplates::HEADER_TEMPLATE
|
36
|
+
.gsub('{FILENAME}', "#{classname}.h")
|
37
|
+
.gsub('{CLASS_NAME}', classname)
|
38
|
+
.gsub('{REUSE_IDENTIFIERS}', reuse_identifier_definitions)
|
39
|
+
.gsub('{SEGUE_IDENTIFIERS}', segue_identifier_definitions)
|
40
|
+
.gsub('{VIEW_CONTROLLERS}', view_controller_definitions)
|
41
|
+
end
|
42
|
+
|
43
|
+
def generate_implementation
|
44
|
+
StoryboardTemplates::IMPLEMENTATION_TEMPLATE
|
45
|
+
.gsub('{FILENAME}', "#{classname}.m")
|
46
|
+
.gsub('{CLASS_NAME}', classname)
|
47
|
+
.gsub('{STATIC_VARIABLES}', static_variables)
|
48
|
+
.gsub('{REUSE_IDENTIFIERS}', reuse_identifier_implementations)
|
49
|
+
.gsub('{SEGUE_IDENTIFIERS}', segue_identifier_implementations)
|
50
|
+
.gsub('{VIEW_CONTROLLERS}', view_controller_implementations)
|
51
|
+
.gsub('{STORYBOARD}', StoryboardTemplates::STORYBOARD_IMPLEMENTATION_TEMPLATE.gsub('{IDENTIFIER_CONSTANT_NAME}', variable_name(storyboard.name)))
|
52
|
+
end
|
53
|
+
|
54
|
+
def static_variables
|
55
|
+
identifiers = (storyboard.cell_reuse_identifiers + storyboard.view_controller_identifiers + storyboard.segue_identifiers + [storyboard.name]).sort
|
56
|
+
identifiers.map do |identifier|
|
57
|
+
StoryboardTemplates::STATIC_IDENTIFIER_TEMPLATE
|
58
|
+
.gsub('{IDENTIFIER}', identifier)
|
59
|
+
.gsub('{IDENTIFIER_CONSTANT_NAME}', variable_name(identifier))
|
60
|
+
end.join("\n")
|
61
|
+
end
|
62
|
+
|
63
|
+
def reuse_identifier_definitions
|
64
|
+
prepend_title(CELL_REUSE_SECTION_TITLE, storyboard.cell_reuse_identifiers.each_with_index.map do |identifier, index|
|
65
|
+
StoryboardTemplates::REUSE_DEFINITION_TEMPLATE.gsub('{IDENTIFIER}', format_reuse_identifier(identifier))
|
66
|
+
end.join("\n"))
|
67
|
+
end
|
68
|
+
|
69
|
+
def reuse_identifier_implementations
|
70
|
+
prepend_title(CELL_REUSE_SECTION_TITLE, storyboard.cell_reuse_identifiers.each_with_index.map do |identifier, index|
|
71
|
+
StoryboardTemplates::REUSE_IMPLEMENTATION_TEMPLATE
|
72
|
+
.gsub('{IDENTIFIER}', format_reuse_identifier(identifier))
|
73
|
+
.gsub('{IDENTIFIER_CONSTANT_NAME}', variable_name(identifier))
|
74
|
+
end.join("\n"))
|
75
|
+
end
|
76
|
+
|
77
|
+
def segue_identifier_definitions
|
78
|
+
prepend_title(SEGUE_SECTION_TITLE, storyboard.segue_identifiers.each_with_index.map do |identifier, index|
|
79
|
+
StoryboardTemplates::SEGUE_DEFINITION_TEMPLATE.gsub('{IDENTIFIER}', format(identifier, 'identifier', 'SegueIdentifier'))
|
80
|
+
end.join("\n"))
|
81
|
+
end
|
82
|
+
|
83
|
+
def segue_identifier_implementations
|
84
|
+
prepend_title(SEGUE_SECTION_TITLE, storyboard.segue_identifiers.each_with_index.map do |identifier, index|
|
85
|
+
StoryboardTemplates::SEGUE_IMPLEMENTATION_TEMPLATE
|
86
|
+
.gsub('{IDENTIFIER}', format_segue_identifier(identifier))
|
87
|
+
.gsub('{IDENTIFIER_CONSTANT_NAME}', variable_name(identifier))
|
88
|
+
end.join("\n"))
|
89
|
+
end
|
90
|
+
|
91
|
+
def view_controller_definitions
|
92
|
+
prepend_title(VIEW_CONTROLLER_SECTION_TITLE, storyboard.view_controller_identifiers.each_with_index.map do |identifier, index|
|
93
|
+
StoryboardTemplates::VIEW_CONTROLLER_DEFINITION_TEMPLATE.gsub('{IDENTIFIER}', format_view_controller(identifier))
|
94
|
+
end.join("\n"))
|
95
|
+
end
|
96
|
+
|
97
|
+
def view_controller_implementations
|
98
|
+
prepend_title(VIEW_CONTROLLER_SECTION_TITLE, storyboard.view_controller_identifiers.each_with_index.map do |identifier, index|
|
99
|
+
StoryboardTemplates::VIEW_CONTROLLER_IMPLEMENTATION_TEMPLATE
|
100
|
+
.gsub('{IDENTIFIER}', variable_name(identifier))
|
101
|
+
.gsub('{CAPITALIZED_IDENTIFIER}', format_view_controller(identifier))
|
102
|
+
end.join("\n"))
|
103
|
+
end
|
104
|
+
|
105
|
+
def variable_name identifier
|
106
|
+
"_#{identifier.gsub(/\W/,'').gsub(/\b\w/){ $&.downcase }}"
|
107
|
+
end
|
108
|
+
|
109
|
+
|
110
|
+
def format_view_controller identifier
|
111
|
+
format(identifier, 'controller', 'ViewController', true)
|
112
|
+
end
|
113
|
+
|
114
|
+
def format_reuse_identifier identifier
|
115
|
+
format(identifier, 'identifier', 'ReuseIdentifier')
|
116
|
+
end
|
117
|
+
|
118
|
+
def format_segue_identifier identifier
|
119
|
+
format(identifier, 'identifier', 'SegueIdentifier')
|
120
|
+
end
|
121
|
+
|
122
|
+
def format identifier, required_suffix, suffix, capitalize=false
|
123
|
+
formatted = identifier.gsub(/\W/,'_')
|
124
|
+
unless formatted =~ /#{required_suffix}$/i
|
125
|
+
formatted = "#{formatted}#{suffix}"
|
126
|
+
end
|
127
|
+
capitalize ? formatted.gsub(/\b\w/){ $&.upcase } : formatted
|
128
|
+
end
|
129
|
+
|
130
|
+
def prepend_title(title, text)
|
131
|
+
if text.length > 0
|
132
|
+
title = StoryboardTemplates::STORYBOARD_SECTION_TITLE_TEMPLATE.gsub('{TITLE}', title)
|
133
|
+
"#{title}\n" + text
|
134
|
+
else
|
135
|
+
text
|
136
|
+
end
|
137
|
+
end
|
138
|
+
end
|
139
|
+
end
|