@sentry/wizard 3.40.0 → 3.41.0

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.
Files changed (103) hide show
  1. package/CHANGELOG.md +8 -1
  2. package/README.md +19 -19
  3. package/bin.ts +5 -0
  4. package/codecov.yml +15 -0
  5. package/dist/bin.js +4 -0
  6. package/dist/bin.js.map +1 -1
  7. package/dist/e2e-tests/jest.config.d.ts +1 -0
  8. package/dist/e2e-tests/jest.config.js +1 -0
  9. package/dist/e2e-tests/jest.config.js.map +1 -1
  10. package/dist/package.json +3 -2
  11. package/dist/src/apple/apple-wizard.js +1 -2
  12. package/dist/src/apple/apple-wizard.js.map +1 -1
  13. package/dist/src/apple/code-tools.d.ts +10 -0
  14. package/dist/src/apple/code-tools.js +16 -12
  15. package/dist/src/apple/code-tools.js.map +1 -1
  16. package/dist/src/apple/fastlane.d.ts +23 -0
  17. package/dist/src/apple/fastlane.js +11 -7
  18. package/dist/src/apple/fastlane.js.map +1 -1
  19. package/dist/src/apple/templates.d.ts +1 -1
  20. package/dist/src/apple/templates.js +0 -2
  21. package/dist/src/apple/templates.js.map +1 -1
  22. package/dist/src/apple/xcode-manager.d.ts +10 -6
  23. package/dist/src/apple/xcode-manager.js +146 -61
  24. package/dist/src/apple/xcode-manager.js.map +1 -1
  25. package/dist/src/nextjs/nextjs-wizard.js +5 -3
  26. package/dist/src/nextjs/nextjs-wizard.js.map +1 -1
  27. package/dist/src/nuxt/nuxt-wizard.js +6 -4
  28. package/dist/src/nuxt/nuxt-wizard.js.map +1 -1
  29. package/dist/src/nuxt/sdk-setup.d.ts +1 -1
  30. package/dist/src/nuxt/sdk-setup.js +2 -1
  31. package/dist/src/nuxt/sdk-setup.js.map +1 -1
  32. package/dist/src/react-native/react-native-wizard.js +5 -3
  33. package/dist/src/react-native/react-native-wizard.js.map +1 -1
  34. package/dist/src/remix/remix-wizard.js +5 -3
  35. package/dist/src/remix/remix-wizard.js.map +1 -1
  36. package/dist/src/run.d.ts +1 -0
  37. package/dist/src/run.js +1 -0
  38. package/dist/src/run.js.map +1 -1
  39. package/dist/src/sveltekit/sveltekit-wizard.js +5 -3
  40. package/dist/src/sveltekit/sveltekit-wizard.js.map +1 -1
  41. package/dist/src/utils/clack-utils.d.ts +3 -1
  42. package/dist/src/utils/clack-utils.js +18 -12
  43. package/dist/src/utils/clack-utils.js.map +1 -1
  44. package/dist/src/utils/package-manager.d.ts +1 -0
  45. package/dist/src/utils/package-manager.js +5 -0
  46. package/dist/src/utils/package-manager.js.map +1 -1
  47. package/dist/src/utils/types.d.ts +9 -0
  48. package/dist/src/utils/types.js.map +1 -1
  49. package/dist/test/apple/cocoapod.test.d.ts +1 -0
  50. package/dist/test/apple/cocoapod.test.js +409 -0
  51. package/dist/test/apple/cocoapod.test.js.map +1 -0
  52. package/dist/test/apple/code-tools.test.d.ts +1 -0
  53. package/dist/test/apple/code-tools.test.js +673 -0
  54. package/dist/test/apple/code-tools.test.js.map +1 -0
  55. package/dist/test/apple/fastfile.test.d.ts +1 -0
  56. package/dist/test/apple/fastfile.test.js +431 -0
  57. package/dist/test/apple/fastfile.test.js.map +1 -0
  58. package/dist/test/apple/templates.test.d.ts +1 -0
  59. package/dist/test/apple/templates.test.js +73 -0
  60. package/dist/test/apple/templates.test.js.map +1 -0
  61. package/dist/test/apple/xcode-manager.test.d.ts +1 -0
  62. package/dist/test/apple/xcode-manager.test.js +834 -0
  63. package/dist/test/apple/xcode-manager.test.js.map +1 -0
  64. package/dist/test/utils/clack-utils.test.js +89 -0
  65. package/dist/test/utils/clack-utils.test.js.map +1 -1
  66. package/e2e-tests/jest.config.ts +1 -0
  67. package/e2e-tests/test-applications/apple/damaged-missing-configuration-list/Project.xcodeproj/project.pbxproj +52 -0
  68. package/e2e-tests/test-applications/apple/damaged-missing-configuration-list/Project.xcodeproj/xcshareddata/xcschemes/Project1.xcscheme +78 -0
  69. package/e2e-tests/test-applications/apple/no-targets/Project.xcodeproj/project.pbxproj +62 -0
  70. package/e2e-tests/test-applications/apple/no-targets/Project.xcodeproj/xcshareddata/xcschemes/Project1.xcscheme +78 -0
  71. package/e2e-tests/test-applications/apple/spm-swiftui-multi-targets/Project.xcodeproj/project.pbxproj +470 -0
  72. package/e2e-tests/test-applications/apple/spm-swiftui-multi-targets/Project.xcodeproj/xcshareddata/xcschemes/Project1.xcscheme +78 -0
  73. package/e2e-tests/test-applications/apple/spm-swiftui-multi-targets/Project1/ContentView.swift +7 -0
  74. package/e2e-tests/test-applications/apple/spm-swiftui-multi-targets/Project1/Project1App.swift +10 -0
  75. package/e2e-tests/test-applications/apple/spm-swiftui-multi-targets/Project2/ContentView.swift +7 -0
  76. package/e2e-tests/test-applications/apple/spm-swiftui-multi-targets/Project2/Project2App.swift +10 -0
  77. package/e2e-tests/test-applications/apple/spm-swiftui-single-target/Project.xcodeproj/project.pbxproj +382 -0
  78. package/e2e-tests/test-applications/apple/spm-swiftui-single-target/Project.xcodeproj/xcshareddata/xcschemes/Project.xcscheme +78 -0
  79. package/e2e-tests/test-applications/apple/spm-swiftui-single-target/Sources/ContentView.swift +7 -0
  80. package/e2e-tests/test-applications/apple/spm-swiftui-single-target/Sources/MainApp.swift +10 -0
  81. package/package.json +3 -2
  82. package/src/apple/apple-wizard.ts +1 -2
  83. package/src/apple/code-tools.ts +21 -6
  84. package/src/apple/fastlane.ts +18 -2
  85. package/src/apple/templates.ts +2 -2
  86. package/src/apple/xcode-manager.ts +181 -94
  87. package/src/nextjs/nextjs-wizard.ts +5 -2
  88. package/src/nuxt/nuxt-wizard.ts +6 -3
  89. package/src/nuxt/sdk-setup.ts +2 -0
  90. package/src/react-native/react-native-wizard.ts +5 -2
  91. package/src/remix/remix-wizard.ts +5 -2
  92. package/src/run.ts +2 -0
  93. package/src/sveltekit/sveltekit-wizard.ts +5 -2
  94. package/src/utils/clack-utils.ts +12 -2
  95. package/src/utils/package-manager.ts +6 -0
  96. package/src/utils/types.ts +10 -0
  97. package/test/apple/cocoapod.test.ts +306 -0
  98. package/test/apple/code-tools.test.ts +1042 -0
  99. package/test/apple/fastfile.test.ts +550 -0
  100. package/test/apple/templates.test.ts +191 -0
  101. package/test/apple/xcode-manager.test.ts +1066 -0
  102. package/test/utils/clack-utils.test.ts +92 -0
  103. package/types/xcode.d.ts +526 -0
@@ -0,0 +1,382 @@
1
+ // !$*UTF8*$!
2
+ {
3
+ archiveVersion = 1;
4
+ classes = {
5
+ };
6
+ objectVersion = 77;
7
+ objects = {
8
+
9
+ /* Begin PBXFileReference section */
10
+ D4E604CD2D50CEEC00CAB00F /* Project.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Project.app; sourceTree = BUILT_PRODUCTS_DIR; };
11
+ /* End PBXFileReference section */
12
+
13
+ /* Begin PBXFileSystemSynchronizedRootGroup section */
14
+ D4E604CF2D50CEEC00CAB00F /* Sources */ = {
15
+ isa = PBXFileSystemSynchronizedRootGroup;
16
+ path = Sources;
17
+ sourceTree = "<group>";
18
+ };
19
+ /* End PBXFileSystemSynchronizedRootGroup section */
20
+
21
+ /* Begin PBXFrameworksBuildPhase section */
22
+ D4E604CA2D50CEEC00CAB00F /* Frameworks */ = {
23
+ isa = PBXFrameworksBuildPhase;
24
+ buildActionMask = 2147483647;
25
+ files = (
26
+ );
27
+ runOnlyForDeploymentPostprocessing = 0;
28
+ };
29
+ /* End PBXFrameworksBuildPhase section */
30
+
31
+ /* Begin PBXGroup section */
32
+ D4E604C42D50CEEC00CAB00F = {
33
+ isa = PBXGroup;
34
+ children = (
35
+ D4E604CF2D50CEEC00CAB00F /* Sources */,
36
+ D4E604CE2D50CEEC00CAB00F /* Products */,
37
+ );
38
+ sourceTree = "<group>";
39
+ };
40
+ D4E604CE2D50CEEC00CAB00F /* Products */ = {
41
+ isa = PBXGroup;
42
+ children = (
43
+ D4E604CD2D50CEEC00CAB00F /* Project.app */,
44
+ );
45
+ name = Products;
46
+ sourceTree = "<group>";
47
+ };
48
+ /* End PBXGroup section */
49
+
50
+ /* Begin PBXNativeTarget section */
51
+ D4E604CC2D50CEEC00CAB00F /* Project */ = {
52
+ isa = PBXNativeTarget;
53
+ buildConfigurationList = D4E604DC2D50CEEE00CAB00F /* Build configuration list for PBXNativeTarget "Project" */;
54
+ buildPhases = (
55
+ D4E604C92D50CEEC00CAB00F /* Sources */,
56
+ D4E604CA2D50CEEC00CAB00F /* Frameworks */,
57
+ D4E604CB2D50CEEC00CAB00F /* Resources */,
58
+ 910B61B94C9A49CF9C0DB695 /* Upload Debug Symbols to Sentry */,
59
+ 39106B6FCD6F4E06BB7C7DDB /* Upload Debug Symbols to Sentry */,
60
+ 1D090A04354641E79E3892CE /* Upload Debug Symbols to Sentry */,
61
+ 60ED433C351442479B9B88E8 /* Upload Debug Symbols to Sentry */,
62
+ C6B94A2F9DE9404596E41FA0 /* Upload Debug Symbols to Sentry */,
63
+ BB1C6E5B39F64292B640DDB3 /* Upload Debug Symbols to Sentry */,
64
+ 0B8595384BF2400E85856945 /* Upload Debug Symbols to Sentry */,
65
+ 7C59361322FB4B5EBA135D71 /* Upload Debug Symbols to Sentry */,
66
+ 80B970F142CF4D33B9BC1A21 /* Upload Debug Symbols to Sentry */,
67
+ CCC77527190A49479702F220 /* Upload Debug Symbols to Sentry */,
68
+ 04F1543989B0451BB1941D24 /* Upload Debug Symbols to Sentry */,
69
+ ED5207A9B66344749E0A8A2E /* Upload Debug Symbols to Sentry */,
70
+ 6032D5B0B1C5428396C44D24 /* Upload Debug Symbols to Sentry */,
71
+ 9929E8CDF61043518A89C77F /* Upload Debug Symbols to Sentry */,
72
+ 492F01B1D1CB454D8C4CA1B5 /* Upload Debug Symbols to Sentry */,
73
+ 0E2FB8DA75E54DAC983BFAC6 /* Upload Debug Symbols to Sentry */,
74
+ B45582F3B2044EA6A76BB688 /* Upload Debug Symbols to Sentry */,
75
+ 9502A69ED35E4283BAEC82DF /* Upload Debug Symbols to Sentry */,
76
+ CC82CF86FD5F465D80572C18 /* Upload Debug Symbols to Sentry */,
77
+ C899C08242754BCF9758341D /* Upload Debug Symbols to Sentry */,
78
+ DDE50AB867AC496C88DA0A6E /* Upload Debug Symbols to Sentry */,
79
+ E3FF44308E64498E9C16B7D8 /* Upload Debug Symbols to Sentry */,
80
+ 352834D2D556471FAAF00443 /* Upload Debug Symbols to Sentry */,
81
+ F94ED4EA60A5427D908718AF /* Upload Debug Symbols to Sentry */,
82
+ );
83
+ buildRules = (
84
+ );
85
+ dependencies = (
86
+ );
87
+ fileSystemSynchronizedGroups = (
88
+ D4E604CF2D50CEEC00CAB00F /* Sources */,
89
+ );
90
+ name = Project;
91
+ packageProductDependencies = (
92
+ );
93
+ productName = SentryWizardSampleBlank;
94
+ productReference = D4E604CD2D50CEEC00CAB00F /* Project.app */;
95
+ productType = "com.apple.product-type.application";
96
+ };
97
+ /* End PBXNativeTarget section */
98
+
99
+ /* Begin PBXProject section */
100
+ D4E604C52D50CEEC00CAB00F /* Project object */ = {
101
+ isa = PBXProject;
102
+ attributes = {
103
+ BuildIndependentTargetsInParallel = 1;
104
+ LastSwiftUpdateCheck = 1620;
105
+ LastUpgradeCheck = 1620;
106
+ TargetAttributes = {
107
+ D4E604CC2D50CEEC00CAB00F = {
108
+ CreatedOnToolsVersion = 16.2;
109
+ };
110
+ };
111
+ };
112
+ buildConfigurationList = D4E604C82D50CEEC00CAB00F /* Build configuration list for PBXProject "Project" */;
113
+ developmentRegion = en;
114
+ hasScannedForEncodings = 0;
115
+ knownRegions = (
116
+ en,
117
+ Base,
118
+ );
119
+ mainGroup = D4E604C42D50CEEC00CAB00F;
120
+ minimizedProjectReferenceProxies = 1;
121
+ preferredProjectObjectVersion = 77;
122
+ productRefGroup = D4E604CE2D50CEEC00CAB00F /* Products */;
123
+ projectDirPath = "";
124
+ projectRoot = "";
125
+ targets = (
126
+ D4E604CC2D50CEEC00CAB00F /* Project */,
127
+ );
128
+ };
129
+ /* End PBXProject section */
130
+
131
+ /* Begin PBXResourcesBuildPhase section */
132
+ D4E604CB2D50CEEC00CAB00F /* Resources */ = {
133
+ isa = PBXResourcesBuildPhase;
134
+ buildActionMask = 2147483647;
135
+ files = (
136
+ );
137
+ runOnlyForDeploymentPostprocessing = 0;
138
+ };
139
+ /* End PBXResourcesBuildPhase section */
140
+
141
+ /* Begin PBXSourcesBuildPhase section */
142
+ D4E604C92D50CEEC00CAB00F /* Sources */ = {
143
+ isa = PBXSourcesBuildPhase;
144
+ buildActionMask = 2147483647;
145
+ files = (
146
+ );
147
+ runOnlyForDeploymentPostprocessing = 0;
148
+ };
149
+ /* End PBXSourcesBuildPhase section */
150
+
151
+ /* Begin XCBuildConfiguration section */
152
+ D4E604DA2D50CEEE00CAB00F /* Debug */ = {
153
+ isa = XCBuildConfiguration;
154
+ buildSettings = {
155
+ ALWAYS_SEARCH_USER_PATHS = NO;
156
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
157
+ CLANG_ANALYZER_NONNULL = YES;
158
+ CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
159
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
160
+ CLANG_ENABLE_MODULES = YES;
161
+ CLANG_ENABLE_OBJC_ARC = YES;
162
+ CLANG_ENABLE_OBJC_WEAK = YES;
163
+ CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
164
+ CLANG_WARN_BOOL_CONVERSION = YES;
165
+ CLANG_WARN_COMMA = YES;
166
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
167
+ CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
168
+ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
169
+ CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
170
+ CLANG_WARN_EMPTY_BODY = YES;
171
+ CLANG_WARN_ENUM_CONVERSION = YES;
172
+ CLANG_WARN_INFINITE_RECURSION = YES;
173
+ CLANG_WARN_INT_CONVERSION = YES;
174
+ CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
175
+ CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
176
+ CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
177
+ CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
178
+ CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
179
+ CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
180
+ CLANG_WARN_STRICT_PROTOTYPES = YES;
181
+ CLANG_WARN_SUSPICIOUS_MOVE = YES;
182
+ CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
183
+ CLANG_WARN_UNREACHABLE_CODE = YES;
184
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
185
+ COPY_PHASE_STRIP = NO;
186
+ DEBUG_INFORMATION_FORMAT = dwarf;
187
+ ENABLE_STRICT_OBJC_MSGSEND = YES;
188
+ ENABLE_TESTABILITY = YES;
189
+ ENABLE_USER_SCRIPT_SANDBOXING = YES;
190
+ GCC_C_LANGUAGE_STANDARD = gnu17;
191
+ GCC_DYNAMIC_NO_PIC = NO;
192
+ GCC_NO_COMMON_BLOCKS = YES;
193
+ GCC_OPTIMIZATION_LEVEL = 0;
194
+ GCC_PREPROCESSOR_DEFINITIONS = (
195
+ "DEBUG=1",
196
+ "$(inherited)",
197
+ );
198
+ GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
199
+ GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
200
+ GCC_WARN_UNDECLARED_SELECTOR = YES;
201
+ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
202
+ GCC_WARN_UNUSED_FUNCTION = YES;
203
+ GCC_WARN_UNUSED_VARIABLE = YES;
204
+ LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
205
+ MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
206
+ MTL_FAST_MATH = YES;
207
+ ONLY_ACTIVE_ARCH = YES;
208
+ SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)";
209
+ SWIFT_OPTIMIZATION_LEVEL = "-Onone";
210
+ };
211
+ name = Debug;
212
+ };
213
+ D4E604DB2D50CEEE00CAB00F /* Release */ = {
214
+ isa = XCBuildConfiguration;
215
+ buildSettings = {
216
+ ALWAYS_SEARCH_USER_PATHS = NO;
217
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
218
+ CLANG_ANALYZER_NONNULL = YES;
219
+ CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
220
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
221
+ CLANG_ENABLE_MODULES = YES;
222
+ CLANG_ENABLE_OBJC_ARC = YES;
223
+ CLANG_ENABLE_OBJC_WEAK = YES;
224
+ CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
225
+ CLANG_WARN_BOOL_CONVERSION = YES;
226
+ CLANG_WARN_COMMA = YES;
227
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
228
+ CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
229
+ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
230
+ CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
231
+ CLANG_WARN_EMPTY_BODY = YES;
232
+ CLANG_WARN_ENUM_CONVERSION = YES;
233
+ CLANG_WARN_INFINITE_RECURSION = YES;
234
+ CLANG_WARN_INT_CONVERSION = YES;
235
+ CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
236
+ CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
237
+ CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
238
+ CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
239
+ CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
240
+ CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
241
+ CLANG_WARN_STRICT_PROTOTYPES = YES;
242
+ CLANG_WARN_SUSPICIOUS_MOVE = YES;
243
+ CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
244
+ CLANG_WARN_UNREACHABLE_CODE = YES;
245
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
246
+ COPY_PHASE_STRIP = NO;
247
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
248
+ ENABLE_NS_ASSERTIONS = NO;
249
+ ENABLE_STRICT_OBJC_MSGSEND = YES;
250
+ ENABLE_USER_SCRIPT_SANDBOXING = YES;
251
+ GCC_C_LANGUAGE_STANDARD = gnu17;
252
+ GCC_NO_COMMON_BLOCKS = YES;
253
+ GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
254
+ GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
255
+ GCC_WARN_UNDECLARED_SELECTOR = YES;
256
+ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
257
+ GCC_WARN_UNUSED_FUNCTION = YES;
258
+ GCC_WARN_UNUSED_VARIABLE = YES;
259
+ LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
260
+ MTL_ENABLE_DEBUG_INFO = NO;
261
+ MTL_FAST_MATH = YES;
262
+ SWIFT_COMPILATION_MODE = wholemodule;
263
+ };
264
+ name = Release;
265
+ };
266
+ D4E604DD2D50CEEE00CAB00F /* Debug */ = {
267
+ isa = XCBuildConfiguration;
268
+ buildSettings = {
269
+ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
270
+ ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
271
+ CODE_SIGN_STYLE = Automatic;
272
+ CURRENT_PROJECT_VERSION = 1;
273
+ ENABLE_PREVIEWS = YES;
274
+ GENERATE_INFOPLIST_FILE = YES;
275
+ "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES;
276
+ "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES;
277
+ "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES;
278
+ "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES;
279
+ "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES;
280
+ "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES;
281
+ "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault;
282
+ "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault;
283
+ INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
284
+ INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
285
+ IPHONEOS_DEPLOYMENT_TARGET = 18.2;
286
+ LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks";
287
+ "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks";
288
+ MACOSX_DEPLOYMENT_TARGET = 15.2;
289
+ MARKETING_VERSION = 1.0;
290
+ PRODUCT_BUNDLE_IDENTIFIER = com.getsentry.SentryWizardSampleBlank;
291
+ PRODUCT_NAME = "$(TARGET_NAME)";
292
+ SDKROOT = auto;
293
+ SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator";
294
+ SWIFT_EMIT_LOC_STRINGS = YES;
295
+ SWIFT_VERSION = 5.0;
296
+ TARGETED_DEVICE_FAMILY = "1,2,7";
297
+ XROS_DEPLOYMENT_TARGET = 2.2;
298
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
299
+ ENABLE_USER_SCRIPT_SANDBOXING = "NO";
300
+ };
301
+ name = Debug;
302
+ };
303
+ D4E604DE2D50CEEE00CAB00F /* Release */ = {
304
+ isa = XCBuildConfiguration;
305
+ buildSettings = {
306
+ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
307
+ ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
308
+ CODE_SIGN_STYLE = Automatic;
309
+ CURRENT_PROJECT_VERSION = 1;
310
+ ENABLE_PREVIEWS = YES;
311
+ GENERATE_INFOPLIST_FILE = YES;
312
+ "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES;
313
+ "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES;
314
+ "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES;
315
+ "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES;
316
+ "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES;
317
+ "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES;
318
+ "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault;
319
+ "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault;
320
+ INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
321
+ INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
322
+ IPHONEOS_DEPLOYMENT_TARGET = 18.2;
323
+ LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks";
324
+ "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks";
325
+ MACOSX_DEPLOYMENT_TARGET = 15.2;
326
+ MARKETING_VERSION = 1.0;
327
+ PRODUCT_BUNDLE_IDENTIFIER = com.getsentry.SentryWizardSampleBlank;
328
+ PRODUCT_NAME = "$(TARGET_NAME)";
329
+ SDKROOT = auto;
330
+ SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator";
331
+ SWIFT_EMIT_LOC_STRINGS = YES;
332
+ SWIFT_VERSION = 5.0;
333
+ TARGETED_DEVICE_FAMILY = "1,2,7";
334
+ XROS_DEPLOYMENT_TARGET = 2.2;
335
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
336
+ ENABLE_USER_SCRIPT_SANDBOXING = "NO";
337
+ };
338
+ name = Release;
339
+ };
340
+ /* End XCBuildConfiguration section */
341
+
342
+ /* Begin XCConfigurationList section */
343
+ D4E604C82D50CEEC00CAB00F /* Build configuration list for PBXProject "Project" */ = {
344
+ isa = XCConfigurationList;
345
+ buildConfigurations = (
346
+ D4E604DA2D50CEEE00CAB00F /* Debug */,
347
+ D4E604DB2D50CEEE00CAB00F /* Release */,
348
+ );
349
+ defaultConfigurationIsVisible = 0;
350
+ defaultConfigurationName = Release;
351
+ };
352
+ D4E604DC2D50CEEE00CAB00F /* Build configuration list for PBXNativeTarget "Project" */ = {
353
+ isa = XCConfigurationList;
354
+ buildConfigurations = (
355
+ D4E604DD2D50CEEE00CAB00F /* Debug */,
356
+ D4E604DE2D50CEEE00CAB00F /* Release */,
357
+ );
358
+ defaultConfigurationIsVisible = 0;
359
+ defaultConfigurationName = Release;
360
+ };
361
+ /* End XCConfigurationList section */
362
+
363
+ /* Begin PBXShellScriptBuildPhase section */
364
+ F94ED4EA60A5427D908718AF /* Upload Debug Symbols to Sentry */ = {
365
+ isa = PBXShellScriptBuildPhase;
366
+ buildActionMask = 2147483647;
367
+ files = (
368
+ );
369
+ runOnlyForDeploymentPostprocessing = 0;
370
+ name = "Upload Debug Symbols to Sentry";
371
+ inputPaths = (
372
+ "${DWARF_DSYM_FOLDER_PATH}/${DWARF_DSYM_FILE_NAME}/Contents/Resources/DWARF/${TARGET_NAME}",
373
+ );
374
+ outputPaths = (
375
+ );
376
+ shellPath = /bin/sh;
377
+ shellScript = "# This script is responsable to upload debug symbols and source context for Sentry.\nif which sentry-cli >/dev/null; then\nexport SENTRY_ORG=sentry\nexport SENTRY_PROJECT=project\nERROR=$(sentry-cli debug-files upload --include-sources \"$DWARF_DSYM_FOLDER_PATH\" 2>&1 >/dev/null)\nif [ ! $? -eq 0 ]; then\necho \"warning: sentry-cli - $ERROR\"\nfi\nelse\necho \"warning: sentry-cli not installed, download from https://github.com/getsentry/sentry-cli/releases\"\nfi\n";
378
+ };
379
+ /* End PBXShellScriptBuildPhase section */
380
+ };
381
+ rootObject = D4E604C52D50CEEC00CAB00F /* Project object */;
382
+ }
@@ -0,0 +1,78 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <Scheme
3
+ LastUpgradeVersion = "1620"
4
+ version = "1.7">
5
+ <BuildAction
6
+ parallelizeBuildables = "YES"
7
+ buildImplicitDependencies = "YES"
8
+ buildArchitectures = "Automatic">
9
+ <BuildActionEntries>
10
+ <BuildActionEntry
11
+ buildForTesting = "YES"
12
+ buildForRunning = "YES"
13
+ buildForProfiling = "YES"
14
+ buildForArchiving = "YES"
15
+ buildForAnalyzing = "YES">
16
+ <BuildableReference
17
+ BuildableIdentifier = "primary"
18
+ BlueprintIdentifier = "D4E604CC2D50CEEC00CAB00F"
19
+ BuildableName = "Project.app"
20
+ BlueprintName = "Project"
21
+ ReferencedContainer = "container:Project.xcodeproj">
22
+ </BuildableReference>
23
+ </BuildActionEntry>
24
+ </BuildActionEntries>
25
+ </BuildAction>
26
+ <TestAction
27
+ buildConfiguration = "Debug"
28
+ selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
29
+ selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
30
+ shouldUseLaunchSchemeArgsEnv = "YES"
31
+ shouldAutocreateTestPlan = "YES">
32
+ </TestAction>
33
+ <LaunchAction
34
+ buildConfiguration = "Debug"
35
+ selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
36
+ selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
37
+ launchStyle = "0"
38
+ useCustomWorkingDirectory = "NO"
39
+ ignoresPersistentStateOnLaunch = "NO"
40
+ debugDocumentVersioning = "YES"
41
+ debugServiceExtension = "internal"
42
+ allowLocationSimulation = "YES">
43
+ <BuildableProductRunnable
44
+ runnableDebuggingMode = "0">
45
+ <BuildableReference
46
+ BuildableIdentifier = "primary"
47
+ BlueprintIdentifier = "D4E604CC2D50CEEC00CAB00F"
48
+ BuildableName = "Project.app"
49
+ BlueprintName = "Project"
50
+ ReferencedContainer = "container:Project.xcodeproj">
51
+ </BuildableReference>
52
+ </BuildableProductRunnable>
53
+ </LaunchAction>
54
+ <ProfileAction
55
+ buildConfiguration = "Release"
56
+ shouldUseLaunchSchemeArgsEnv = "YES"
57
+ savedToolIdentifier = ""
58
+ useCustomWorkingDirectory = "NO"
59
+ debugDocumentVersioning = "YES">
60
+ <BuildableProductRunnable
61
+ runnableDebuggingMode = "0">
62
+ <BuildableReference
63
+ BuildableIdentifier = "primary"
64
+ BlueprintIdentifier = "D4E604CC2D50CEEC00CAB00F"
65
+ BuildableName = "Project.app"
66
+ BlueprintName = "Project"
67
+ ReferencedContainer = "container:Project.xcodeproj">
68
+ </BuildableReference>
69
+ </BuildableProductRunnable>
70
+ </ProfileAction>
71
+ <AnalyzeAction
72
+ buildConfiguration = "Debug">
73
+ </AnalyzeAction>
74
+ <ArchiveAction
75
+ buildConfiguration = "Release"
76
+ revealArchiveInOrganizer = "YES">
77
+ </ArchiveAction>
78
+ </Scheme>
@@ -0,0 +1,7 @@
1
+ import SwiftUI
2
+
3
+ struct ContentView: View {
4
+ var body: some View {
5
+ Text("Hello, world!")
6
+ }
7
+ }
@@ -0,0 +1,10 @@
1
+ import SwiftUI
2
+
3
+ @main
4
+ struct MainApp: App {
5
+ var body: some Scene {
6
+ WindowGroup {
7
+ ContentView()
8
+ }
9
+ }
10
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/wizard",
3
- "version": "3.40.0",
3
+ "version": "3.41.0",
4
4
  "homepage": "https://github.com/getsentry/sentry-wizard",
5
5
  "repository": "https://github.com/getsentry/sentry-wizard",
6
6
  "description": "Sentry wizard helping you to configure your project",
@@ -123,5 +123,6 @@
123
123
  "volta": {
124
124
  "node": "14.18.3",
125
125
  "yarn": "1.22.19"
126
- }
126
+ },
127
+ "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
127
128
  }
@@ -17,7 +17,6 @@ import { traceStep, withTelemetry } from '../telemetry';
17
17
  import * as cocoapod from './cocoapod';
18
18
  import * as fastlane from './fastlane';
19
19
 
20
- const xcode = require('xcode');
21
20
  /* eslint-enable @typescript-eslint/no-unused-vars */
22
21
 
23
22
  import {
@@ -161,7 +160,7 @@ async function runAppleWizardWithTelementry(
161
160
 
162
161
  Sentry.setTag('package-manager', hasCocoa ? 'cocoapods' : 'SPM');
163
162
  traceStep('Update Xcode project', () => {
164
- xcProject.updateXcodeProject(project, target, apiKey, !hasCocoa, true);
163
+ xcProject.updateXcodeProject(project, target, !hasCocoa, true);
165
164
  });
166
165
 
167
166
  const codeAdded = traceStep('Add code snippet', () => {
@@ -1,15 +1,15 @@
1
+ import * as Sentry from '@sentry/node';
1
2
  import * as fs from 'fs';
2
3
  import * as path from 'path';
3
4
  import * as templates from './templates';
4
- import * as Sentry from '@sentry/node';
5
5
  // @ts-ignore - clack is ESM and TS complains about that. It works though
6
- import clack from '@clack/prompts';
6
+ import * as clack from '@clack/prompts';
7
7
 
8
8
  const swiftAppLaunchRegex =
9
- /(func\s+application\s*\(_\sapplication:[^,]+,\s*didFinishLaunchingWithOptions[^,]+:[^)]+\)\s+->\s+Bool\s+{)|func\s+applicationDidFinishLaunching\(_\s+aNotification:\s+Notification\)\s+{/im;
9
+ /(func\s+application\s*\(\s*_\s+application:\s*[^,]+,\s*didFinishLaunchingWithOptions[^,]+:\s*[^)]+\s*\)\s+->\s+Bool\s+{)|func\s+applicationDidFinishLaunching\s*\(\s*_\s+aNotification:\s+Notification\s*\)\s*{/im;
10
10
  const objcAppLaunchRegex =
11
- /-\s*\(BOOL\)\s*application:\s*\(UIApplication\s*\*\)\s*application\s+didFinishLaunchingWithOptions:\s*\(NSDictionary\s*\*\)\s*launchOptions\s*{/im;
12
- const swiftUIRegex = /@main\s+struct[^:]+:\s*App\s*{/im;
11
+ /-\s*\(\s*BOOL\s*\)\s*application:\s*\(\s*UIApplication\s*\*\s*\)\s*application\s+didFinishLaunchingWithOptions:\s*\(\s*NSDictionary\s*\*\s*\)\s*launchOptions\s*{/im;
12
+ const swiftUIRegex = /@main\s+struct[^:]+:\s*(SwiftUI\.)?App\s*{/im;
13
13
 
14
14
  function isAppDelegateFile(filePath: string): boolean {
15
15
  const appLaunchRegex = filePath.toLowerCase().endsWith('.swift')
@@ -43,7 +43,7 @@ function findAppDidFinishLaunchingWithOptions(
43
43
  return filePath;
44
44
  }
45
45
  } else if (
46
- !filePath.startsWith('.') &&
46
+ !path.basename(filePath).startsWith('.') &&
47
47
  !filePath.endsWith('.xcodeproj') &&
48
48
  !filePath.endsWith('.xcassets') &&
49
49
  fs.existsSync(filePath) &&
@@ -97,6 +97,7 @@ export function addCodeSnippetToProject(
97
97
  if (!match) {
98
98
  const swiftUIMatch = swiftUIRegex.exec(fileContent);
99
99
  if (!swiftUIMatch) {
100
+ // This branch is not reached, because we already checked for SwiftUI in isAppDelegateFile
100
101
  return false;
101
102
  }
102
103
  //Is SwiftUI with no init
@@ -130,3 +131,17 @@ export function addCodeSnippetToProject(
130
131
  clack.log.step('Added Sentry initialization code snippet to ' + appDelegate);
131
132
  return true;
132
133
  }
134
+
135
+ /**
136
+ * Exported for testing purposes, but should not be used in other modules.
137
+ */
138
+ export let exportForTesting: {
139
+ isAppDelegateFile: typeof isAppDelegateFile;
140
+ findAppDidFinishLaunchingWithOptions: typeof findAppDidFinishLaunchingWithOptions;
141
+ };
142
+ if (process.env.NODE_ENV === 'test') {
143
+ exportForTesting = {
144
+ isAppDelegateFile,
145
+ findAppDidFinishLaunchingWithOptions,
146
+ };
147
+ }
@@ -1,9 +1,9 @@
1
1
  import * as fs from 'fs';
2
2
  import * as path from 'path';
3
- import * as templates from './templates';
4
3
  import { askForItemSelection } from '../utils/clack-utils';
4
+ import * as templates from './templates';
5
5
  // @ts-ignore - clack is ESM and TS complains about that. It works though
6
- import clack from '@clack/prompts';
6
+ import * as clack from '@clack/prompts';
7
7
 
8
8
  export function fastFile(projectPath: string): string | null {
9
9
  const fastlanePath = path.join(projectPath, 'fastlane', 'Fastfile');
@@ -152,3 +152,19 @@ export async function addSentryToFastlane(
152
152
  fs.writeFileSync(fastFilePath, newFileContent, 'utf8');
153
153
  return true;
154
154
  }
155
+
156
+ /**
157
+ * Exported for testing purposes, but should not be used in other modules.
158
+ */
159
+ export let exportForTesting: {
160
+ findIOSPlatform: typeof findIOSPlatform;
161
+ findLanes: typeof findLanes;
162
+ addSentryToLane: typeof addSentryToLane;
163
+ };
164
+ if (process.env.NODE_ENV === 'test') {
165
+ exportForTesting = {
166
+ findIOSPlatform,
167
+ findLanes,
168
+ addSentryToLane,
169
+ };
170
+ }
@@ -1,8 +1,8 @@
1
1
  export function getRunScriptTemplate(
2
2
  orgSlug: string,
3
3
  projectSlug: string,
4
- uploadSource = true,
5
- includeHomebrewPath = false,
4
+ uploadSource: boolean,
5
+ includeHomebrewPath: boolean,
6
6
  ): string {
7
7
  // eslint-disable-next-line no-useless-escape
8
8
  const includeHomebrew = includeHomebrewPath