Skip to content

Commit b74b4a5

Browse files
author
Ali Abdelfattah
authored
Merge pull request #572 from Instabug/fix/ios-autolinking
[MOB-5143] Fix/iOS Autolinking
2 parents c660677 + 17ce573 commit b74b4a5

File tree

5 files changed

+12
-76
lines changed

5 files changed

+12
-76
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
* Bumps Instabug native SDKs to v10.8
44
* Adds string keys for the discard attachment prompt dialog.
5+
* Fixes Autolinking on iOS.
56

67
## v10.4.0 (2021-05-10)
78

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@ Updating to a new version? Check the [Update Guide](#update-guide) before bumpin
3030
yarn add instabug-reactnative
3131
```
3232

33-
2. For projects that build for iOS, install `xcodeproj` gem:
33+
2. CocoaPods on iOS needs this extra step:
3434

3535
```bash
36-
gem install xcodeproj
36+
cd ios && pod install && cd ..
3737
```
3838

3939
3. **For React Native >= 0.60**, simply run the command:

autolink.rb

Lines changed: 0 additions & 39 deletions
This file was deleted.

autounlink.rb

Lines changed: 0 additions & 30 deletions
This file was deleted.

react-native.config.js

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
module.exports = {
22
dependency: {
33
platforms: {
4-
ios: {},
4+
ios: {
5+
scriptPhases: [
6+
{
7+
name: '[instabug-reactnative] Upload Sourcemap',
8+
script: 'bash "../node_modules/instabug-reactnative/ios/upload_sourcemap.sh"',
9+
execution_position: 'after_compile',
10+
},
11+
],
12+
},
513
android: {
614
},
715
},
@@ -13,17 +21,13 @@ module.exports = {
1321
{
1422
name: 'add-instabug',
1523
func: () => {
16-
const exec = require('child_process').exec;
1724
require('./link_gradle');
18-
exec("ruby ./node_modules/instabug-reactnative/autolink.rb || echo \"Ruby doesn't exist, if you're building this for Android only, then feel free to ignore this error, otherwise please install Ruby and run 'react-native link instabug-reactnative' again\"");
1925
},
2026
},
2127
{
2228
name: 'remove-instabug',
2329
func: () => {
24-
const exec = require('child_process').exec;
2530
require('./unlink_gradle');
26-
exec("ruby ./node_modules/instabug-reactnative/autounlink.rb || echo \"Ruby doesn't exist, if you're building this for Android only, then feel free to ignore this error, otherwise please install Ruby and run 'react-native link instabug-reactnative' again\"");
2731
},
2832
},
2933
],

0 commit comments

Comments
 (0)