@sentry/wizard 3.42.1 → 4.0.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 (338) hide show
  1. package/.node-cache/node-v22.14.0-darwin-arm64 +0 -0
  2. package/.node-cache/node-v22.14.0-darwin-x64 +0 -0
  3. package/.node-cache/node-v22.14.0-linux-arm64 +0 -0
  4. package/.node-cache/node-v22.14.0-linux-x64 +0 -0
  5. package/.node-cache/node-v22.14.0-win-x64.exe +0 -0
  6. package/CHANGELOG.md +26 -0
  7. package/COPYING +3575 -0
  8. package/bin.ts +85 -80
  9. package/dist/bin.js +44 -35
  10. package/dist/bin.js.map +1 -1
  11. package/dist/e2e-tests/jest.config.js +1 -1
  12. package/dist/e2e-tests/jest.config.js.map +1 -1
  13. package/dist/e2e-tests/tests/flutter.test.js +62 -147
  14. package/dist/e2e-tests/tests/flutter.test.js.map +1 -1
  15. package/dist/e2e-tests/tests/nextjs.test.js +77 -175
  16. package/dist/e2e-tests/tests/nextjs.test.js.map +1 -1
  17. package/dist/e2e-tests/tests/nuxt-3.test.js +61 -162
  18. package/dist/e2e-tests/tests/nuxt-3.test.js.map +1 -1
  19. package/dist/e2e-tests/tests/nuxt-4.test.js +62 -163
  20. package/dist/e2e-tests/tests/nuxt-4.test.js.map +1 -1
  21. package/dist/e2e-tests/tests/remix.test.js +147 -189
  22. package/dist/e2e-tests/tests/remix.test.js.map +1 -1
  23. package/dist/e2e-tests/tests/sveltekit.test.js +133 -187
  24. package/dist/e2e-tests/tests/sveltekit.test.js.map +1 -1
  25. package/dist/e2e-tests/utils/index.d.ts +1 -1
  26. package/dist/e2e-tests/utils/index.js +113 -195
  27. package/dist/e2e-tests/utils/index.js.map +1 -1
  28. package/dist/lib/Constants.js +5 -5
  29. package/dist/lib/Constants.js.map +1 -1
  30. package/dist/lib/Helper/BottomBar.d.ts +1 -1
  31. package/dist/lib/Helper/BottomBar.js +14 -15
  32. package/dist/lib/Helper/BottomBar.js.map +1 -1
  33. package/dist/lib/Helper/Env.js +5 -2
  34. package/dist/lib/Helper/Env.js.map +1 -1
  35. package/dist/lib/Helper/File.js +14 -27
  36. package/dist/lib/Helper/File.js.map +1 -1
  37. package/dist/lib/Helper/Git.js +24 -59
  38. package/dist/lib/Helper/Git.js.map +1 -1
  39. package/dist/lib/Helper/Logging.js +2 -2
  40. package/dist/lib/Helper/Logging.js.map +1 -1
  41. package/dist/lib/Helper/MergeConfig.js +4 -4
  42. package/dist/lib/Helper/MergeConfig.js.map +1 -1
  43. package/dist/lib/Helper/Package.d.ts +4 -1
  44. package/dist/lib/Helper/Package.js +12 -38
  45. package/dist/lib/Helper/Package.js.map +1 -1
  46. package/dist/lib/Helper/SentryCli.js +77 -149
  47. package/dist/lib/Helper/SentryCli.js.map +1 -1
  48. package/dist/lib/Helper/Wizard.js +29 -124
  49. package/dist/lib/Helper/Wizard.js.map +1 -1
  50. package/dist/lib/Helper/__tests__/File.js +4 -4
  51. package/dist/lib/Helper/__tests__/File.js.map +1 -1
  52. package/dist/lib/Helper/__tests__/MergeConfig.js +24 -24
  53. package/dist/lib/Helper/__tests__/MergeConfig.js.map +1 -1
  54. package/dist/lib/Helper/__tests__/SentryCli.js +33 -23
  55. package/dist/lib/Helper/__tests__/SentryCli.js.map +1 -1
  56. package/dist/lib/Setup.js +23 -85
  57. package/dist/lib/Setup.js.map +1 -1
  58. package/dist/lib/Steps/BaseStep.js +8 -8
  59. package/dist/lib/Steps/BaseStep.js.map +1 -1
  60. package/dist/lib/Steps/ChooseIntegration.js +80 -125
  61. package/dist/lib/Steps/ChooseIntegration.js.map +1 -1
  62. package/dist/lib/Steps/ConfigureProject.js +6 -66
  63. package/dist/lib/Steps/ConfigureProject.js.map +1 -1
  64. package/dist/lib/Steps/Initial.js +16 -104
  65. package/dist/lib/Steps/Initial.js.map +1 -1
  66. package/dist/lib/Steps/Integrations/BaseIntegration.js +24 -118
  67. package/dist/lib/Steps/Integrations/BaseIntegration.js.map +1 -1
  68. package/dist/lib/Steps/Integrations/Cordova.js +95 -183
  69. package/dist/lib/Steps/Integrations/Cordova.js.map +1 -1
  70. package/dist/lib/Steps/Integrations/Electron.js +87 -145
  71. package/dist/lib/Steps/Integrations/Electron.js.map +1 -1
  72. package/dist/lib/Steps/Integrations/MobileProject.js +40 -148
  73. package/dist/lib/Steps/Integrations/MobileProject.js.map +1 -1
  74. package/dist/lib/Steps/OpenSentry.js +63 -126
  75. package/dist/lib/Steps/OpenSentry.js.map +1 -1
  76. package/dist/lib/Steps/PromptForParameters.js +110 -206
  77. package/dist/lib/Steps/PromptForParameters.js.map +1 -1
  78. package/dist/lib/Steps/Result.js +19 -79
  79. package/dist/lib/Steps/Result.js.map +1 -1
  80. package/dist/lib/Steps/SentryProjectSelector.js +57 -148
  81. package/dist/lib/Steps/SentryProjectSelector.js.map +1 -1
  82. package/dist/lib/Steps/ShouldConfigure.js +6 -66
  83. package/dist/lib/Steps/ShouldConfigure.js.map +1 -1
  84. package/dist/lib/Steps/WaitForSentry.js +43 -120
  85. package/dist/lib/Steps/WaitForSentry.js.map +1 -1
  86. package/dist/lib/Steps/Welcome.js +17 -76
  87. package/dist/lib/Steps/Welcome.js.map +1 -1
  88. package/dist/lib/__tests__/Env.js +3 -3
  89. package/dist/lib/__tests__/Env.js.map +1 -1
  90. package/dist/src/android/android-wizard.js +100 -176
  91. package/dist/src/android/android-wizard.js.map +1 -1
  92. package/dist/src/android/code-tools.js +24 -33
  93. package/dist/src/android/code-tools.js.map +1 -1
  94. package/dist/src/android/gradle.js +106 -165
  95. package/dist/src/android/gradle.js.map +1 -1
  96. package/dist/src/android/manifest.js +26 -27
  97. package/dist/src/android/manifest.js.map +1 -1
  98. package/dist/src/android/templates.js +76 -23
  99. package/dist/src/android/templates.js.map +1 -1
  100. package/dist/src/apple/apple-wizard.js +129 -225
  101. package/dist/src/apple/apple-wizard.js.map +1 -1
  102. package/dist/src/apple/cocoapod.js +47 -109
  103. package/dist/src/apple/cocoapod.js.map +1 -1
  104. package/dist/src/apple/code-tools.js +32 -35
  105. package/dist/src/apple/code-tools.js.map +1 -1
  106. package/dist/src/apple/fastlane.js +51 -97
  107. package/dist/src/apple/fastlane.js.map +1 -1
  108. package/dist/src/apple/templates.js +41 -5
  109. package/dist/src/apple/templates.js.map +1 -1
  110. package/dist/src/apple/xcode-manager.d.ts +2 -2
  111. package/dist/src/apple/xcode-manager.js +93 -108
  112. package/dist/src/apple/xcode-manager.js.map +1 -1
  113. package/dist/src/flutter/code-tools.js +79 -127
  114. package/dist/src/flutter/code-tools.js.map +1 -1
  115. package/dist/src/flutter/flutter-wizard.js +75 -136
  116. package/dist/src/flutter/flutter-wizard.js.map +1 -1
  117. package/dist/src/flutter/templates.js +48 -12
  118. package/dist/src/flutter/templates.js.map +1 -1
  119. package/dist/src/nextjs/nextjs-wizard.js +527 -805
  120. package/dist/src/nextjs/nextjs-wizard.js.map +1 -1
  121. package/dist/src/nextjs/templates.js +380 -40
  122. package/dist/src/nextjs/templates.js.map +1 -1
  123. package/dist/src/nextjs/utils.js +5 -5
  124. package/dist/src/nextjs/utils.js.map +1 -1
  125. package/dist/src/nuxt/nuxt-wizard.js +91 -188
  126. package/dist/src/nuxt/nuxt-wizard.js.map +1 -1
  127. package/dist/src/nuxt/sdk-example.js +68 -137
  128. package/dist/src/nuxt/sdk-example.js.map +1 -1
  129. package/dist/src/nuxt/sdk-setup.d.ts +4 -4
  130. package/dist/src/nuxt/sdk-setup.js +180 -336
  131. package/dist/src/nuxt/sdk-setup.js.map +1 -1
  132. package/dist/src/nuxt/templates.js +195 -18
  133. package/dist/src/nuxt/templates.js.map +1 -1
  134. package/dist/src/nuxt/utils.js +29 -76
  135. package/dist/src/nuxt/utils.js.map +1 -1
  136. package/dist/src/react-native/expo-env-file.js +41 -94
  137. package/dist/src/react-native/expo-env-file.js.map +1 -1
  138. package/dist/src/react-native/expo-metro.d.ts +1 -1
  139. package/dist/src/react-native/expo-metro.js +75 -130
  140. package/dist/src/react-native/expo-metro.js.map +1 -1
  141. package/dist/src/react-native/expo.js +61 -114
  142. package/dist/src/react-native/expo.js.map +1 -1
  143. package/dist/src/react-native/git.js +23 -56
  144. package/dist/src/react-native/git.js.map +1 -1
  145. package/dist/src/react-native/glob.js +3 -3
  146. package/dist/src/react-native/glob.js.map +1 -1
  147. package/dist/src/react-native/gradle.js +4 -4
  148. package/dist/src/react-native/gradle.js.map +1 -1
  149. package/dist/src/react-native/javascript.js +51 -95
  150. package/dist/src/react-native/javascript.js.map +1 -1
  151. package/dist/src/react-native/metro.js +176 -296
  152. package/dist/src/react-native/metro.js.map +1 -1
  153. package/dist/src/react-native/react-native-wizard.js +267 -418
  154. package/dist/src/react-native/react-native-wizard.js.map +1 -1
  155. package/dist/src/react-native/uninstall.js +37 -80
  156. package/dist/src/react-native/uninstall.js.map +1 -1
  157. package/dist/src/react-native/xcode.js +57 -55
  158. package/dist/src/react-native/xcode.js.map +1 -1
  159. package/dist/src/remix/codemods/express-server.js +27 -82
  160. package/dist/src/remix/codemods/express-server.js.map +1 -1
  161. package/dist/src/remix/codemods/handle-error.js +28 -31
  162. package/dist/src/remix/codemods/handle-error.js.map +1 -1
  163. package/dist/src/remix/codemods/root-common.js +11 -11
  164. package/dist/src/remix/codemods/root-common.js.map +1 -1
  165. package/dist/src/remix/codemods/root-v1.js +17 -67
  166. package/dist/src/remix/codemods/root-v1.js.map +1 -1
  167. package/dist/src/remix/codemods/root-v2.js +89 -140
  168. package/dist/src/remix/codemods/root-v2.js.map +1 -1
  169. package/dist/src/remix/remix-wizard.js +181 -343
  170. package/dist/src/remix/remix-wizard.js.map +1 -1
  171. package/dist/src/remix/sdk-example.js +84 -66
  172. package/dist/src/remix/sdk-example.js.map +1 -1
  173. package/dist/src/remix/sdk-setup.js +161 -293
  174. package/dist/src/remix/sdk-setup.js.map +1 -1
  175. package/dist/src/remix/templates.js +10 -2
  176. package/dist/src/remix/templates.js.map +1 -1
  177. package/dist/src/remix/utils.js +13 -14
  178. package/dist/src/remix/utils.js.map +1 -1
  179. package/dist/src/run.js +106 -178
  180. package/dist/src/run.js.map +1 -1
  181. package/dist/src/sourcemaps/sourcemaps-wizard.js +248 -372
  182. package/dist/src/sourcemaps/sourcemaps-wizard.js.map +1 -1
  183. package/dist/src/sourcemaps/tools/angular.js +32 -66
  184. package/dist/src/sourcemaps/tools/angular.js.map +1 -1
  185. package/dist/src/sourcemaps/tools/create-react-app.js +14 -59
  186. package/dist/src/sourcemaps/tools/create-react-app.js.map +1 -1
  187. package/dist/src/sourcemaps/tools/esbuild.js +34 -77
  188. package/dist/src/sourcemaps/tools/esbuild.js.map +1 -1
  189. package/dist/src/sourcemaps/tools/nextjs.d.ts +2 -2
  190. package/dist/src/sourcemaps/tools/nextjs.js +75 -102
  191. package/dist/src/sourcemaps/tools/nextjs.js.map +1 -1
  192. package/dist/src/sourcemaps/tools/remix.js +53 -93
  193. package/dist/src/sourcemaps/tools/remix.js.map +1 -1
  194. package/dist/src/sourcemaps/tools/rollup.js +35 -76
  195. package/dist/src/sourcemaps/tools/rollup.js.map +1 -1
  196. package/dist/src/sourcemaps/tools/sentry-cli.js +157 -289
  197. package/dist/src/sourcemaps/tools/sentry-cli.js.map +1 -1
  198. package/dist/src/sourcemaps/tools/tsc.js +68 -134
  199. package/dist/src/sourcemaps/tools/tsc.js.map +1 -1
  200. package/dist/src/sourcemaps/tools/vite.js +111 -196
  201. package/dist/src/sourcemaps/tools/vite.js.map +1 -1
  202. package/dist/src/sourcemaps/tools/webpack.d.ts +1 -1
  203. package/dist/src/sourcemaps/tools/webpack.js +158 -260
  204. package/dist/src/sourcemaps/tools/webpack.js.map +1 -1
  205. package/dist/src/sourcemaps/utils/detect-tool.js +9 -54
  206. package/dist/src/sourcemaps/utils/detect-tool.js.map +1 -1
  207. package/dist/src/sourcemaps/utils/other-wizards.js +77 -144
  208. package/dist/src/sourcemaps/utils/other-wizards.js.map +1 -1
  209. package/dist/src/sourcemaps/utils/sdk-version.js +112 -191
  210. package/dist/src/sourcemaps/utils/sdk-version.js.map +1 -1
  211. package/dist/src/sveltekit/sdk-example.js +20 -70
  212. package/dist/src/sveltekit/sdk-example.js.map +1 -1
  213. package/dist/src/sveltekit/sdk-setup.js +250 -411
  214. package/dist/src/sveltekit/sdk-setup.js.map +1 -1
  215. package/dist/src/sveltekit/sveltekit-wizard.js +107 -191
  216. package/dist/src/sveltekit/sveltekit-wizard.js.map +1 -1
  217. package/dist/src/sveltekit/templates.js +147 -13
  218. package/dist/src/sveltekit/templates.js.map +1 -1
  219. package/dist/src/sveltekit/utils.js +3 -3
  220. package/dist/src/sveltekit/utils.js.map +1 -1
  221. package/dist/src/telemetry.d.ts +2 -2
  222. package/dist/src/telemetry.js +58 -108
  223. package/dist/src/telemetry.js.map +1 -1
  224. package/dist/src/utils/ast-utils.js +39 -54
  225. package/dist/src/utils/ast-utils.js.map +1 -1
  226. package/dist/src/utils/bash.js +28 -75
  227. package/dist/src/utils/bash.js.map +1 -1
  228. package/dist/src/utils/clack-utils.d.ts +3 -7
  229. package/dist/src/utils/clack-utils.js +688 -1083
  230. package/dist/src/utils/clack-utils.js.map +1 -1
  231. package/dist/src/utils/debug.js +6 -10
  232. package/dist/src/utils/debug.js.map +1 -1
  233. package/dist/src/utils/package-json.js +5 -6
  234. package/dist/src/utils/package-json.js.map +1 -1
  235. package/dist/src/utils/package-manager.js +65 -139
  236. package/dist/src/utils/package-manager.js.map +1 -1
  237. package/dist/src/utils/release-registry.js +12 -59
  238. package/dist/src/utils/release-registry.js.map +1 -1
  239. package/dist/src/utils/semver.js +3 -4
  240. package/dist/src/utils/semver.js.map +1 -1
  241. package/dist/src/utils/sentrycli-utils.js +4 -4
  242. package/dist/src/utils/sentrycli-utils.js.map +1 -1
  243. package/dist/src/utils/url.js +5 -6
  244. package/dist/src/utils/url.js.map +1 -1
  245. package/dist/test/android/code-tools.test.js +18 -18
  246. package/dist/test/android/code-tools.test.js.map +1 -1
  247. package/dist/test/apple/cocoapod.test.js +154 -299
  248. package/dist/test/apple/cocoapod.test.js.map +1 -1
  249. package/dist/test/apple/code-tools.test.js +375 -263
  250. package/dist/test/apple/code-tools.test.js.map +1 -1
  251. package/dist/test/apple/fastfile.test.js +319 -271
  252. package/dist/test/apple/fastfile.test.js.map +1 -1
  253. package/dist/test/apple/templates.test.js +114 -30
  254. package/dist/test/apple/templates.test.js.map +1 -1
  255. package/dist/test/apple/xcode-manager.test.js +230 -234
  256. package/dist/test/apple/xcode-manager.test.js.map +1 -1
  257. package/dist/test/flutter/code-tools.test.js +119 -48
  258. package/dist/test/flutter/code-tools.test.js.map +1 -1
  259. package/dist/test/flutter/templates.test.js +63 -20
  260. package/dist/test/flutter/templates.test.js.map +1 -1
  261. package/dist/test/nextjs/templates.test.js +332 -43
  262. package/dist/test/nextjs/templates.test.js.map +1 -1
  263. package/dist/test/nuxt/templates.test.js +161 -33
  264. package/dist/test/nuxt/templates.test.js.map +1 -1
  265. package/dist/test/react-native/expo-metro.test.js +61 -15
  266. package/dist/test/react-native/expo-metro.test.js.map +1 -1
  267. package/dist/test/react-native/expo.test.js +37 -17
  268. package/dist/test/react-native/expo.test.js.map +1 -1
  269. package/dist/test/react-native/gradle.test.js +260 -28
  270. package/dist/test/react-native/gradle.test.js.map +1 -1
  271. package/dist/test/react-native/javascript.test.js +85 -19
  272. package/dist/test/react-native/javascript.test.js.map +1 -1
  273. package/dist/test/react-native/metro.test.js +261 -187
  274. package/dist/test/react-native/metro.test.js.map +1 -1
  275. package/dist/test/react-native/xcode.test.js +243 -62
  276. package/dist/test/react-native/xcode.test.js.map +1 -1
  277. package/dist/test/remix/client-entry.test.js +81 -21
  278. package/dist/test/remix/client-entry.test.js.map +1 -1
  279. package/dist/test/remix/server-instrumentation.test.js +21 -8
  280. package/dist/test/remix/server-instrumentation.test.js.map +1 -1
  281. package/dist/test/sourcemaps/tools/sentry-cli.test.js +20 -72
  282. package/dist/test/sourcemaps/tools/sentry-cli.test.js.map +1 -1
  283. package/dist/test/sourcemaps/tools/tsc.test.js +142 -68
  284. package/dist/test/sourcemaps/tools/tsc.test.js.map +1 -1
  285. package/dist/test/sourcemaps/tools/vite.test.js +106 -75
  286. package/dist/test/sourcemaps/tools/vite.test.js.map +1 -1
  287. package/dist/test/sourcemaps/tools/webpack.test.js +226 -102
  288. package/dist/test/sourcemaps/tools/webpack.test.js.map +1 -1
  289. package/dist/test/sveltekit/templates.test.js +117 -18
  290. package/dist/test/sveltekit/templates.test.js.map +1 -1
  291. package/dist/test/utils/ast-utils.test.js +99 -58
  292. package/dist/test/utils/ast-utils.test.js.map +1 -1
  293. package/dist/test/utils/clack-utils.test.js +142 -247
  294. package/dist/test/utils/clack-utils.test.js.map +1 -1
  295. package/e2e-tests/package.json +1 -1
  296. package/e2e-tests/tests/flutter.test.ts +20 -20
  297. package/e2e-tests/tests/nextjs.test.ts +2 -2
  298. package/e2e-tests/tests/nuxt-3.test.ts +4 -4
  299. package/e2e-tests/tests/nuxt-4.test.ts +3 -3
  300. package/e2e-tests/tests/remix.test.ts +3 -3
  301. package/e2e-tests/tests/sveltekit.test.ts +3 -3
  302. package/e2e-tests/utils/index.ts +33 -15
  303. package/lib/Helper/BottomBar.ts +1 -1
  304. package/lib/Helper/Env.ts +1 -1
  305. package/lib/Helper/Package.ts +12 -10
  306. package/lib/Helper/SentryCli.ts +18 -27
  307. package/lib/Helper/Wizard.ts +1 -2
  308. package/lib/Setup.ts +4 -5
  309. package/lib/Steps/ChooseIntegration.ts +40 -8
  310. package/lib/Steps/Initial.ts +17 -26
  311. package/lib/Steps/Integrations/BaseIntegration.ts +2 -8
  312. package/lib/Steps/Integrations/Cordova.ts +9 -15
  313. package/lib/Steps/Integrations/Electron.ts +23 -20
  314. package/lib/Steps/Integrations/MobileProject.ts +18 -15
  315. package/lib/Steps/OpenSentry.ts +12 -7
  316. package/lib/Steps/PromptForParameters.ts +12 -19
  317. package/lib/Steps/SentryProjectSelector.ts +30 -29
  318. package/lib/Steps/WaitForSentry.ts +29 -23
  319. package/package.json +12 -8
  320. package/src/apple/xcode-manager.ts +10 -10
  321. package/src/nextjs/templates.ts +2 -3
  322. package/src/nuxt/sdk-setup.ts +21 -18
  323. package/src/react-native/expo-metro.ts +2 -2
  324. package/src/react-native/react-native-wizard.ts +1 -2
  325. package/src/react-native/uninstall.ts +1 -2
  326. package/src/react-native/xcode.ts +1 -1
  327. package/src/run.ts +12 -5
  328. package/src/sourcemaps/tools/nextjs.ts +2 -2
  329. package/src/sourcemaps/tools/webpack.ts +3 -3
  330. package/src/telemetry.ts +27 -7
  331. package/src/utils/clack-utils.ts +50 -47
  332. package/test/apple/cocoapod.test.ts +4 -0
  333. package/test/apple/fastfile.test.ts +12 -7
  334. package/test/apple/xcode-manager.test.ts +13 -11
  335. package/test/utils/clack-utils.test.ts +40 -50
  336. package/types/read-env.d.ts +3 -0
  337. package/types/xcode.d.ts +1 -0
  338. package/dist/package.json +0 -128
@@ -54,8 +54,7 @@ import { patchExpoAppConfig, printSentryExpoMigrationOutro } from './expo';
54
54
  import { addSentryToExpoMetroConfig } from './expo-metro';
55
55
  import { addExpoEnvLocal } from './expo-env-file';
56
56
 
57
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
58
- const xcode = require('xcode');
57
+ import xcode from 'xcode';
59
58
 
60
59
  export const RN_SDK_PACKAGE = '@sentry/react-native';
61
60
  export const RN_SDK_SUPPORTED_RANGE = '>=5.0.0';
@@ -23,8 +23,7 @@ import {
23
23
  import { ReactNativeWizardOptions } from './options';
24
24
  import { unPatchMetroConfig } from './metro';
25
25
 
26
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
27
- const xcode = require('xcode');
26
+ import xcode from 'xcode';
28
27
 
29
28
  export async function runReactNativeUninstall(
30
29
  options: ReactNativeWizardOptions,
@@ -1,7 +1,7 @@
1
1
  /* eslint-disable @typescript-eslint/no-unsafe-assignment */
2
2
  /* eslint-disable @typescript-eslint/no-unsafe-call */
3
3
  /* eslint-disable @typescript-eslint/no-unsafe-member-access */
4
- import * as fs from 'fs';
4
+ import * as fs from 'node:fs';
5
5
  // @ts-ignore - clack is ESM and TS complains about that. It works though
6
6
  import clack from '@clack/prompts';
7
7
  import chalk from 'chalk';
package/src/run.ts CHANGED
@@ -16,6 +16,7 @@ import { runSourcemapsWizard } from './sourcemaps/sourcemaps-wizard';
16
16
  import { readEnvironment } from '../lib/Helper/Env';
17
17
  import type { Platform } from '../lib/Constants';
18
18
  import type { PackageDotJson } from './utils/package-json';
19
+ import { readFileSync } from 'node:fs';
19
20
 
20
21
  type WizardIntegration =
21
22
  | 'reactNative'
@@ -195,10 +196,16 @@ export async function run(argv: Args) {
195
196
  * TODO: replace with rollup replace whenever we switch to rollup
196
197
  */
197
198
  function tryGetWizardVersion(): string {
198
- try {
199
- const wizardPkgJson = require('../package.json') as PackageDotJson;
200
- return wizardPkgJson.version ?? '';
201
- } catch {
202
- return '';
199
+ let version = process.env.npm_package_version;
200
+ if (!version) {
201
+ try {
202
+ const wizardPkgJson = JSON.parse(
203
+ readFileSync('../package.json', 'utf-8'),
204
+ ) as PackageDotJson;
205
+ version = wizardPkgJson.version;
206
+ } catch {
207
+ // ignore
208
+ }
203
209
  }
210
+ return version ?? '';
204
211
  }
@@ -7,9 +7,9 @@ import {
7
7
  abortIfCancelled,
8
8
  addDotEnvSentryBuildPluginFile,
9
9
  } from '../../utils/clack-utils';
10
- import { WizardOptions } from '../../utils/types';
10
+ import type { WizardOptions } from '../../utils/types';
11
11
 
12
- import { SourceMapUploadToolConfigurationOptions } from './types';
12
+ import type { SourceMapUploadToolConfigurationOptions } from './types';
13
13
 
14
14
  import * as Sentry from '@sentry/node';
15
15
 
@@ -1,5 +1,5 @@
1
- import * as path from 'path';
2
- import * as fs from 'fs';
1
+ import * as path from 'node:path';
2
+ import * as fs from 'node:fs';
3
3
 
4
4
  // @ts-ignore - clack is ESM and TS complains about that. It works though
5
5
  import * as clack from '@clack/prompts';
@@ -23,7 +23,7 @@ import {
23
23
  } from '../../utils/clack-utils';
24
24
  import { hasPackageInstalled } from '../../utils/package-json';
25
25
 
26
- import {
26
+ import type {
27
27
  SourceMapUploadToolConfigurationFunction,
28
28
  SourceMapUploadToolConfigurationOptions,
29
29
  } from './types';
package/src/telemetry.ts CHANGED
@@ -1,18 +1,19 @@
1
1
  import {
2
- defaultStackParser,
3
2
  Hub,
4
3
  Integrations,
4
+ NodeClient,
5
+ type Span,
6
+ defaultStackParser,
7
+ flush,
5
8
  makeMain,
6
9
  makeNodeTransport,
7
- NodeClient,
8
10
  runWithAsyncContext,
9
11
  setTag,
10
12
  startSpan,
11
- flush,
12
- Span,
13
13
  } from '@sentry/node';
14
- import packageJson from '../package.json';
15
- import { WizardOptions } from './utils/types';
14
+ import { readFileSync } from 'node:fs';
15
+ import { dirname, join } from 'node:path';
16
+ import type { WizardOptions } from './utils/types';
16
17
 
17
18
  export async function withTelemetry<F>(
18
19
  options: {
@@ -68,6 +69,25 @@ export async function withTelemetry<F>(
68
69
  }
69
70
 
70
71
  function createSentryInstance(enabled: boolean, integration: string) {
72
+ let version: string | undefined = process.env.npm_package_version;
73
+ if (!version) {
74
+ try {
75
+ const pathToPackageJson = join(
76
+ dirname(require.resolve('@sentry/wizard')),
77
+ '..',
78
+ 'package.json',
79
+ );
80
+ const packageJsonData = readFileSync(pathToPackageJson, 'utf-8');
81
+ const parsedPackageJson = JSON.parse(packageJsonData) as {
82
+ version?: string;
83
+ };
84
+ version = parsedPackageJson.version;
85
+ } catch {
86
+ // If we fail to read the package.json file, we don't want to crash the wizard
87
+ // so we just don't set the version
88
+ }
89
+ }
90
+
71
91
  const client = new NodeClient({
72
92
  dsn: 'https://8871d3ff64814ed8960c96d1fcc98a27@o1.ingest.sentry.io/4505425820712960',
73
93
  enabled: enabled,
@@ -77,7 +97,7 @@ function createSentryInstance(enabled: boolean, integration: string) {
77
97
  tracesSampleRate: 1,
78
98
  sampleRate: 1,
79
99
 
80
- release: packageJson.version,
100
+ release: version,
81
101
  integrations: [new Integrations.Http()],
82
102
  tracePropagationTargets: [/^https:\/\/sentry.io\//],
83
103
 
@@ -1,31 +1,25 @@
1
+ import * as childProcess from 'node:child_process';
2
+ import * as fs from 'node:fs';
3
+ import * as os from 'node:os';
4
+ import { basename, dirname, isAbsolute, join, relative } from 'node:path';
5
+ import { setInterval } from 'node:timers';
6
+ import { URL } from 'node:url';
1
7
  // @ts-ignore - clack is ESM and TS complains about that. It works though
2
8
  import * as clack from '@clack/prompts';
9
+ import * as Sentry from '@sentry/node';
3
10
  import axios from 'axios';
4
11
  import chalk from 'chalk';
5
- import * as childProcess from 'child_process';
6
- import * as fs from 'fs';
7
- import * as path from 'path';
8
- import * as os from 'os';
9
- import { setInterval } from 'timers';
10
- import { URL } from 'url';
11
- import * as Sentry from '@sentry/node';
12
- import { hasPackageInstalled, PackageDotJson } from './package-json';
13
- import { Feature, SentryProjectData, WizardOptions } from './types';
12
+ import opn from 'opn';
14
13
  import { traceStep } from '../telemetry';
14
+ import { debug } from './debug';
15
+ import { type PackageDotJson, hasPackageInstalled } from './package-json';
15
16
  import {
17
+ type PackageManager,
16
18
  detectPackageManger,
17
- PackageManager,
18
19
  packageManagers,
19
20
  } from './package-manager';
20
- import { debug } from './debug';
21
21
  import { fulfillsVersionRange } from './semver';
22
-
23
- export const opn = require('opn') as (
24
- url: string,
25
- options?: {
26
- wait?: boolean;
27
- },
28
- ) => Promise<childProcess.ChildProcess>;
22
+ import type { Feature, SentryProjectData, WizardOptions } from './types';
29
23
 
30
24
  export const SENTRY_DOT_ENV_FILE = '.env.sentry-build-plugin';
31
25
  export const SENTRY_CLI_RC_FILE = '.sentryclirc';
@@ -145,23 +139,32 @@ export async function abortIfCancelled<T>(
145
139
  }
146
140
  }
147
141
 
142
+ type PackageJSON = { version?: string };
143
+
148
144
  export function printWelcome(options: {
149
145
  wizardName: string;
150
146
  promoCode?: string;
151
147
  message?: string;
152
148
  telemetryEnabled?: boolean;
153
149
  }): void {
154
- let wizardPackage: { version?: string } = {};
155
-
156
- try {
157
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
158
- wizardPackage = require(path.join(
159
- path.dirname(require.resolve('@sentry/wizard')),
160
- '..',
161
- 'package.json',
162
- ));
163
- } catch {
164
- // We don't need to have this
150
+ let wizardVersion = process.env.npm_package_version;
151
+ if (!wizardVersion) {
152
+ try {
153
+ wizardVersion = (
154
+ JSON.parse(
155
+ fs.readFileSync(
156
+ join(
157
+ dirname(require.resolve('@sentry/wizard')),
158
+ '..',
159
+ 'package.json',
160
+ ),
161
+ 'utf-8',
162
+ ),
163
+ ) as PackageJSON
164
+ ).version;
165
+ } catch {
166
+ // We don't need to have this
167
+ }
165
168
  }
166
169
 
167
170
  // eslint-disable-next-line no-console
@@ -176,8 +179,8 @@ export function printWelcome(options: {
176
179
  welcomeText = `${welcomeText}\n\nUsing promo-code: ${options.promoCode}`;
177
180
  }
178
181
 
179
- if (wizardPackage.version) {
180
- welcomeText = `${welcomeText}\n\nVersion: ${wizardPackage.version}`;
182
+ if (wizardVersion) {
183
+ welcomeText = `${welcomeText}\n\nVersion: ${wizardVersion}`;
181
184
  }
182
185
 
183
186
  if (options.telemetryEnabled) {
@@ -408,7 +411,7 @@ export async function installPackage({
408
411
  if (err) {
409
412
  // Write a log file so we can better troubleshoot issues
410
413
  fs.writeFileSync(
411
- path.join(
414
+ join(
412
415
  process.cwd(),
413
416
  `sentry-wizard-installation-error-${Date.now()}.log`,
414
417
  ),
@@ -454,7 +457,7 @@ export async function addSentryCliConfig(
454
457
  setupConfig: CliSetupConfig = rcCliSetupConfig,
455
458
  ): Promise<void> {
456
459
  return traceStep('add-sentry-cli-config', async () => {
457
- const configPath = path.join(process.cwd(), setupConfig.filename);
460
+ const configPath = join(process.cwd(), setupConfig.filename);
458
461
  const configExists = fs.existsSync(configPath);
459
462
 
460
463
  let configContents =
@@ -597,7 +600,7 @@ export async function addDotEnvSentryBuildPluginFile(
597
600
  SENTRY_AUTH_TOKEN=${authToken}
598
601
  `;
599
602
 
600
- const dotEnvFilePath = path.join(process.cwd(), SENTRY_DOT_ENV_FILE);
603
+ const dotEnvFilePath = join(process.cwd(), SENTRY_DOT_ENV_FILE);
601
604
  const dotEnvFileExists = fs.existsSync(dotEnvFilePath);
602
605
 
603
606
  if (dotEnvFileExists) {
@@ -658,7 +661,7 @@ SENTRY_AUTH_TOKEN=${authToken}
658
661
  }
659
662
 
660
663
  async function addCliConfigFileToGitIgnore(filename: string): Promise<void> {
661
- const gitignorePath = path.join(process.cwd(), '.gitignore');
664
+ const gitignorePath = join(process.cwd(), '.gitignore');
662
665
 
663
666
  try {
664
667
  const gitignoreContent = await fs.promises.readFile(gitignorePath, 'utf8');
@@ -794,7 +797,7 @@ export async function ensurePackageIsInstalled(
794
797
 
795
798
  export async function getPackageDotJson(): Promise<PackageDotJson> {
796
799
  const packageJsonFileContents = await fs.promises
797
- .readFile(path.join(process.cwd(), 'package.json'), 'utf8')
800
+ .readFile(join(process.cwd(), 'package.json'), 'utf8')
798
801
  .catch(() => {
799
802
  clack.log.error(
800
803
  'Could not find package.json. Make sure to run the wizard in the root of your app!',
@@ -825,7 +828,7 @@ export async function updatePackageDotJson(
825
828
  ): Promise<void> {
826
829
  try {
827
830
  await fs.promises.writeFile(
828
- path.join(process.cwd(), 'package.json'),
831
+ join(process.cwd(), 'package.json'),
829
832
  // TODO: maybe figure out the original indentation
830
833
  JSON.stringify(packageDotJson, null, 2),
831
834
  {
@@ -865,7 +868,7 @@ export async function getPackageManager(): Promise<PackageManager> {
865
868
 
866
869
  export function isUsingTypeScript() {
867
870
  try {
868
- return fs.existsSync(path.join(process.cwd(), 'tsconfig.json'));
871
+ return fs.existsSync(join(process.cwd(), 'tsconfig.json'));
869
872
  } catch {
870
873
  return false;
871
874
  }
@@ -1127,9 +1130,9 @@ async function askForWizardLogin(options: {
1127
1130
  )}\n\n${chalk.cyan(urlToOpen)}`,
1128
1131
  );
1129
1132
 
1130
- opn(urlToOpen, { wait: false }).catch(() => {
1131
- // opn throws in environments that don't have a browser (e.g. remote shells) so we just noop here
1132
- });
1133
+ // opn throws in environments that don't have a browser (e.g. remote shells) so we just noop here
1134
+ const noop = () => {}; // eslint-disable-line @typescript-eslint/no-empty-function
1135
+ opn(urlToOpen, { wait: false }).then((cp) => cp.on('error', noop), noop);
1133
1136
 
1134
1137
  const loginSpinner = clack.spinner();
1135
1138
 
@@ -1276,7 +1279,7 @@ export async function askForToolConfigPath(
1276
1279
  return await abortIfCancelled(
1277
1280
  clack.text({
1278
1281
  message: `Please enter the path to your ${toolName} config file:`,
1279
- placeholder: path.join('.', configFileName),
1282
+ placeholder: join('.', configFileName),
1280
1283
  validate: (value) => {
1281
1284
  if (!value) {
1282
1285
  return 'Please enter a path.';
@@ -1323,9 +1326,9 @@ export async function showCopyPasteInstructions(
1323
1326
  hint?: string,
1324
1327
  ): Promise<void> {
1325
1328
  clack.log.step(
1326
- `Add the following code to your ${chalk.cyan(
1327
- path.basename(filename),
1328
- )} file:${hint ? chalk.dim(` (${chalk.dim(hint)})`) : ''}`,
1329
+ `Add the following code to your ${chalk.cyan(basename(filename))} file:${
1330
+ hint ? chalk.dim(` (${chalk.dim(hint)})`) : ''
1331
+ }`,
1329
1332
  );
1330
1333
 
1331
1334
  // Padding the code snippet to be printed with a \n at the beginning and end
@@ -1406,12 +1409,12 @@ export async function createNewConfigFile(
1406
1409
  codeSnippet: string,
1407
1410
  moreInformation?: string,
1408
1411
  ): Promise<boolean> {
1409
- if (!path.isAbsolute(filepath)) {
1412
+ if (!isAbsolute(filepath)) {
1410
1413
  debug(`createNewConfigFile: filepath is not absolute: ${filepath}`);
1411
1414
  return false;
1412
1415
  }
1413
1416
 
1414
- const prettyFilename = chalk.cyan(path.relative(process.cwd(), filepath));
1417
+ const prettyFilename = chalk.cyan(relative(process.cwd(), filepath));
1415
1418
 
1416
1419
  try {
1417
1420
  await fs.promises.writeFile(filepath, codeSnippet);
@@ -10,6 +10,10 @@ import {
10
10
  import * as bash from '../../src/utils/bash';
11
11
  // @ts-ignore - clack is ESM and TS complains about that. It works though
12
12
  import * as clack from '@clack/prompts';
13
+ jest.mock('@clack/prompts', () => ({
14
+ __esModule: true,
15
+ ...jest.requireActual('@clack/prompts'),
16
+ }));
13
17
 
14
18
  jest.mock('../../src/utils/bash');
15
19
  jest.spyOn(Sentry, 'setTag').mockImplementation();
@@ -1,6 +1,6 @@
1
- import * as fs from 'fs';
2
- import * as os from 'os';
3
- import * as path from 'path';
1
+ import * as fs from 'node:fs';
2
+ import * as os from 'node:os';
3
+ import * as path from 'node:path';
4
4
  import {
5
5
  addSentryToFastlane,
6
6
  exportForTesting,
@@ -9,6 +9,11 @@ import {
9
9
  // @ts-ignore - clack is ESM and TS complains about that. It works though
10
10
  import * as clack from '@clack/prompts';
11
11
 
12
+ jest.mock('@clack/prompts', () => ({
13
+ __esModule: true,
14
+ ...jest.requireActual('@clack/prompts'),
15
+ }));
16
+
12
17
  describe('fastlane', () => {
13
18
  beforeEach(() => {
14
19
  jest.spyOn(clack.log, 'warn').mockImplementation();
@@ -422,7 +427,7 @@ end
422
427
  platform :ios do
423
428
  lane :test do
424
429
  puts 'Hello, world!'
425
- end
430
+ end
426
431
  end
427
432
  `,
428
433
  );
@@ -443,7 +448,7 @@ platform :ios do
443
448
  project_slug: 'test-project',
444
449
  include_sources: true
445
450
  )
446
- end
451
+ end
447
452
  end
448
453
  `,
449
454
  );
@@ -463,7 +468,7 @@ end
463
468
  `platform :ios do
464
469
  lane :test do
465
470
  puts 'Hello, world!'
466
- end
471
+ end
467
472
 
468
473
  lane :beta do
469
474
  puts 'Beta lane'
@@ -505,7 +510,7 @@ end
505
510
  `platform :ios do
506
511
  lane :test do
507
512
  puts 'Hello, world!'
508
- end
513
+ end
509
514
 
510
515
  lane :beta do
511
516
  puts 'Beta lane'
@@ -1,7 +1,7 @@
1
- import * as fs from 'fs';
2
- import * as os from 'os';
3
- import * as path from 'path';
4
- import {
1
+ import * as fs from 'node:fs';
2
+ import * as os from 'node:os';
3
+ import * as path from 'node:path';
4
+ import type {
5
5
  PBXFileReference,
6
6
  PBXGroup,
7
7
  PBXNativeTarget,
@@ -11,15 +11,17 @@ import {
11
11
  } from 'xcode';
12
12
  import { getRunScriptTemplate } from '../../src/apple/templates';
13
13
  import { XcodeProject } from '../../src/apple/xcode-manager';
14
- import { SentryProjectData } from '../../src/utils/types';
14
+ import type { SentryProjectData } from '../../src/utils/types';
15
15
 
16
+ jest.mock('node:fs', () => ({
17
+ __esModule: true,
18
+ ...jest.requireActual('node:fs'),
19
+ }));
16
20
  jest.mock('@clack/prompts', () => ({
17
- default: {
18
- log: {
19
- info: jest.fn(),
20
- success: jest.fn(),
21
- step: jest.fn(),
22
- },
21
+ log: {
22
+ info: jest.fn(),
23
+ success: jest.fn(),
24
+ step: jest.fn(),
23
25
  },
24
26
  }));
25
27
 
@@ -4,43 +4,33 @@ import {
4
4
  installPackage,
5
5
  } from '../../src/utils/clack-utils';
6
6
 
7
- import * as fs from 'fs';
8
- import * as ChildProcess from 'child_process';
9
- import { PackageManager } from '../../src/utils/package-manager';
10
-
11
- type ClackMock = {
12
- confirm: jest.Mock;
13
- text: jest.Mock;
14
- isCancel: jest.Mock;
15
- cancel: jest.Mock;
7
+ import * as fs from 'node:fs';
8
+ import * as ChildProcess from 'node:child_process';
9
+ import type { PackageManager } from '../../src/utils/package-manager';
10
+
11
+ // @ts-ignore - clack is ESM and TS complains about that. It works though
12
+ import * as clack from '@clack/prompts';
13
+
14
+ jest.mock('node:child_process', () => ({
15
+ __esModule: true,
16
+ ...jest.requireActual('node:child_process'),
17
+ }));
18
+
19
+ jest.mock('@clack/prompts', () => ({
16
20
  log: {
17
- info: jest.Mock;
18
- success: jest.Mock;
19
- warn: jest.Mock;
20
- };
21
- spinner: () => { start: jest.Mock; stop: jest.Mock };
22
- };
23
-
24
- let clackMock: ClackMock;
25
-
26
- jest.mock('@clack/prompts', () => {
27
- clackMock = {
28
- log: {
29
- info: jest.fn(),
30
- success: jest.fn(),
31
- warn: jest.fn(),
32
- },
33
- text: jest.fn(),
34
- confirm: jest.fn(),
35
- cancel: jest.fn(),
36
- // passthrough for abortIfCancelled
37
- isCancel: jest.fn().mockReturnValue(false),
38
- spinner: jest
39
- .fn()
40
- .mockImplementation(() => ({ start: jest.fn(), stop: jest.fn() })),
41
- };
42
- return clackMock;
43
- });
21
+ info: jest.fn(),
22
+ success: jest.fn(),
23
+ warn: jest.fn(),
24
+ },
25
+ text: jest.fn(),
26
+ confirm: jest.fn(),
27
+ cancel: jest.fn(),
28
+ // passthrough for abortIfCancelled
29
+ isCancel: jest.fn().mockReturnValue(false),
30
+ spinner: jest
31
+ .fn()
32
+ .mockImplementation(() => ({ start: jest.fn(), stop: jest.fn() })),
33
+ }));
44
34
 
45
35
  function mockUserResponse(fn: jest.Mock, response: any) {
46
36
  fn.mockReturnValueOnce(response);
@@ -52,11 +42,11 @@ describe('askForToolConfigPath', () => {
52
42
  });
53
43
 
54
44
  it('returns undefined if users have no config file', async () => {
55
- mockUserResponse(clackMock.confirm, false);
45
+ mockUserResponse(clack.confirm as jest.Mock, false);
56
46
 
57
47
  const result = await askForToolConfigPath('Webpack', 'webpack.config.js');
58
48
 
59
- expect(clackMock.confirm).toHaveBeenCalledWith(
49
+ expect(clack.confirm).toHaveBeenCalledWith(
60
50
  expect.objectContaining({
61
51
  message: expect.stringContaining('have a Webpack config file'),
62
52
  }),
@@ -66,18 +56,18 @@ describe('askForToolConfigPath', () => {
66
56
  });
67
57
 
68
58
  it('returns the path if users have a config file and the entered path is valid', async () => {
69
- mockUserResponse(clackMock.confirm, true);
70
- mockUserResponse(clackMock.text, 'my.webpack.config.js');
59
+ mockUserResponse(clack.confirm as jest.Mock, true);
60
+ mockUserResponse(clack.text as jest.Mock, 'my.webpack.config.js');
71
61
 
72
62
  const result = await askForToolConfigPath('Webpack', 'webpack.config.js');
73
63
 
74
- expect(clackMock.confirm).toHaveBeenCalledWith(
64
+ expect(clack.confirm).toHaveBeenCalledWith(
75
65
  expect.objectContaining({
76
66
  message: expect.stringContaining('have a Webpack config file'),
77
67
  }),
78
68
  );
79
69
 
80
- expect(clackMock.text).toHaveBeenCalledWith(
70
+ expect(clack.text).toHaveBeenCalledWith(
81
71
  expect.objectContaining({
82
72
  message: expect.stringContaining(
83
73
  'enter the path to your Webpack config file',
@@ -99,8 +89,8 @@ describe('createNewConfigFile', () => {
99
89
  .spyOn(fs.promises, 'writeFile')
100
90
  .mockImplementation(jest.fn());
101
91
 
102
- const filename = '/weboack.config.js';
103
- const code = `module.exports = {/*config...*/}`;
92
+ const filename = '/webpack.config.js';
93
+ const code = 'module.exports = {/*config...*/}';
104
94
 
105
95
  const result = await createNewConfigFile(filename, code);
106
96
 
@@ -111,14 +101,14 @@ describe('createNewConfigFile', () => {
111
101
  it('logs more information if provided as an argument', async () => {
112
102
  jest.spyOn(fs.promises, 'writeFile').mockImplementation(jest.fn());
113
103
 
114
- const filename = '/weboack.config.js';
115
- const code = `module.exports = {/*config...*/}`;
104
+ const filename = '/webpack.config.js';
105
+ const code = 'module.exports = {/*config...*/}';
116
106
  const moreInfo = 'More information...';
117
107
 
118
108
  await createNewConfigFile(filename, code, moreInfo);
119
109
 
120
- expect(clackMock.log.info).toHaveBeenCalledTimes(1);
121
- expect(clackMock.log.info).toHaveBeenCalledWith(
110
+ expect(clack.log.info).toHaveBeenCalledTimes(1);
111
+ expect(clack.log.info).toHaveBeenCalledWith(
122
112
  expect.stringContaining(moreInfo),
123
113
  );
124
114
  });
@@ -129,13 +119,13 @@ describe('createNewConfigFile', () => {
129
119
  .mockImplementation(() => Promise.reject(new Error('Could not write')));
130
120
 
131
121
  const filename = '/webpack.config.js';
132
- const code = `module.exports = {/*config...*/}`;
122
+ const code = 'module.exports = {/*config...*/}';
133
123
 
134
124
  const result = await createNewConfigFile(filename, code);
135
125
 
136
126
  expect(result).toBe(false);
137
127
  expect(writeFileSpy).toHaveBeenCalledWith(filename, code);
138
- expect(clackMock.log.warn).toHaveBeenCalledTimes(1);
128
+ expect(clack.log.warn).toHaveBeenCalledTimes(1);
139
129
  });
140
130
 
141
131
  it('returns false if the passed path is not absolute', async () => {
@@ -0,0 +1,3 @@
1
+ declare module "read-env" {
2
+ export default function readEnv(name: string): Record<string, unknown>;
3
+ }
package/types/xcode.d.ts CHANGED
@@ -165,6 +165,7 @@ declare module 'xcode' {
165
165
  }
166
166
 
167
167
  export interface PBXShellScriptBuildPhase {
168
+ isa?: string;
168
169
  shellScript: string;
169
170
  inputFileListPaths?: string[];
170
171
  outputFileListPaths?: string[];