Skip to content

Commit

Permalink
appcenter removed, ios build succeeded (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kamill90 authored Apr 2, 2020
1 parent aac522b commit 0d7d85c
Show file tree
Hide file tree
Showing 14 changed files with 9,894 additions and 161 deletions.
9 changes: 1 addition & 8 deletions App.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import { Chain } from './models/bitcoinUnits';
import QuickActions from 'react-native-quick-actions';
import * as Sentry from '@sentry/react-native';
import OnAppLaunch from './class/onAppLaunch';
const A = require('./analytics');

if (process.env.NODE_ENV !== 'development') {
Sentry.init({
Expand Down Expand Up @@ -110,16 +109,11 @@ export default class App extends React.Component {
_handleAppStateChange = async nextAppState => {
if (BlueApp.getWallets().length > 0) {
if (this.state.appState.match(/inactive|background/) && nextAppState === 'active') {
A(A.ENUM.APP_UNSUSPENDED);
const clipboard = await Clipboard.getString();
const isAddressFromStoredWallet = BlueApp.getWallets().some(wallet =>
wallet.chain === Chain.ONCHAIN ? wallet.weOwnAddress(clipboard) : wallet.isInvoiceGeneratedByWallet(clipboard),
);
if (
!isAddressFromStoredWallet &&
this.state.clipboardContent !== clipboard &&
(this.isBitcoinAddress(clipboard))
) {
if (!isAddressFromStoredWallet && this.state.clipboardContent !== clipboard && this.isBitcoinAddress(clipboard)) {
this.setState({ isClipboardContentModalVisible: true });
}
this.setState({ clipboardContent: clipboard });
Expand Down Expand Up @@ -181,7 +175,6 @@ export default class App extends React.Component {
}),
);
} else {
return;
}
};

Expand Down
30 changes: 0 additions & 30 deletions analytics.js

This file was deleted.

1 change: 0 additions & 1 deletion android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ project.ext.react = [
]

apply from: "../../node_modules/react-native/react.gradle"
apply from: "../../node_modules/@sentry/react-native/sentry.gradle"

/**
* Set this to true to create two separate APKs instead of one:
Expand Down
3 changes: 0 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ import App from './App';
import LottieView from 'lottie-react-native';
import UnlockWith from './UnlockWith.js';

const A = require('./analytics');

if (!Error.captureStackTrace) {
// captureStackTrace is only available when debugging
Error.captureStackTrace = () => {};
Expand All @@ -28,7 +26,6 @@ class BlueAppComponent extends React.Component {
}

setIsMigratingData = async () => {
A(A.ENUM.INIT);
this.setState({ isMigratingData: false });
};

Expand Down
20 changes: 2 additions & 18 deletions ios/GoldWallet.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
};
objectVersion = 46;
objects = {

/* Begin PBXBuildFile section */
00E356F31AD99517003FC87E /* GoldWalletTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* GoldWalletTests.m */; };
036397B3AA70DD314F31661C /* libPods-GoldWalletWatch Extension.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 154B05BEF3C3512F67A08374 /* libPods-GoldWalletWatch Extension.a */; };
Expand Down Expand Up @@ -572,7 +571,6 @@
00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
B40D4E2D225841C300428FCC /* Embed Watch Content */,
791C03B6EF06B63A39F55115 /* [CP] Copy Pods Resources */,
2130DE983D1D45AC8FC45F7E /* Upload Debug Symbols to Sentry */,
3271B0B6236E2E0700DA766F /* Embed App Extensions */,
);
buildRules = (
Expand Down Expand Up @@ -832,7 +830,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "export SENTRY_PROPERTIES=sentry.properties\nexport NODE_BINARY=node\n../node_modules/@sentry/cli/bin/sentry-cli react-native xcode ../node_modules/react-native/scripts/react-native-xcode.sh\n";
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh\n";
};
0E6D0FA885BDBE9988699506 /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
Expand All @@ -856,20 +854,6 @@
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
showEnvVarsInLog = 0;
};
2130DE983D1D45AC8FC45F7E /* Upload Debug Symbols to Sentry */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Upload Debug Symbols to Sentry";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "export SENTRY_PROPERTIES=sentry.properties\n../node_modules/@sentry/cli/bin/sentry-cli upload-dsym";
};
2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
Expand All @@ -882,7 +866,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "export SENTRY_PROPERTIES=sentry.properties\nexport NODE_BINARY=node\n../node_modules/@sentry/cli/bin/sentry-cli react-native xcode ../node_modules/react-native/scripts/react-native-xcode.sh";
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
};
310D9B5C1860199135C315EC /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
Expand Down
9 changes: 1 addition & 8 deletions ios/GoldWallet/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,12 @@
#import <React/RCTBundleURLProvider.h>
#import <React/RCTRootView.h>
#import "RNQuickActionManager.h"
#import <AppCenterReactNativeShared/AppCenterReactNativeShared.h>
#import <AppCenterReactNative.h>
#import <AppCenterReactNativeAnalytics.h>
#import <AppCenterReactNativeCrashes.h>

@implementation AppDelegate

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[AppCenterReactNative register];
[AppCenterReactNativeAnalytics registerWithInitiallyEnabled:true];
[AppCenterReactNativeCrashes registerWithAutomaticProcessing];


NSURL *jsCodeLocation;

jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
Expand Down
70 changes: 18 additions & 52 deletions ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,22 +1,4 @@
PODS:
- appcenter (2.6.0):
- AppCenterReactNativeShared
- React
- appcenter-analytics (2.6.0):
- AppCenter/Analytics
- AppCenterReactNativeShared
- React
- appcenter-crashes (2.6.0):
- AppCenter/Crashes
- AppCenterReactNativeShared
- React
- AppCenter/Analytics (2.5.1):
- AppCenter/Core
- AppCenter/Core (2.5.1)
- AppCenter/Crashes (2.5.1):
- AppCenter/Core
- AppCenterReactNativeShared (2.6.0):
- AppCenter/Core (= 2.5.1)
- boost-for-react-native (1.63.0)
- BVLinearGradient (2.5.4):
- React
Expand Down Expand Up @@ -131,7 +113,7 @@ PODS:
- React
- RemobileReactNativeQrcodeLocalImage (1.0.4):
- React
- RNCAsyncStorage (1.6.2):
- RNCAsyncStorage (1.7.1):
- React
- RNDefaultPreference (1.4.1):
- React
Expand Down Expand Up @@ -160,9 +142,9 @@ PODS:
- React
- RNWatch (0.4.1):
- React
- Sentry (4.4.2):
- Sentry/Core (= 4.4.2)
- Sentry/Core (4.4.2)
- Sentry (4.4.3):
- Sentry/Core (= 4.4.3)
- Sentry/Core (4.4.3)
- swift_qrcodejs (1.1.2)
- TcpSockets (3.3.2):
- React
Expand All @@ -171,9 +153,6 @@ PODS:
- yoga (0.60.5.React)

DEPENDENCIES:
- appcenter (from `../node_modules/appcenter/ios`)
- appcenter-analytics (from `../node_modules/appcenter-analytics/ios`)
- appcenter-crashes (from `../node_modules/appcenter-crashes/ios`)
- BVLinearGradient (from `../node_modules/react-native-linear-gradient`)
- DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`)
- EFQRCode (= 5.1.0)
Expand Down Expand Up @@ -226,22 +205,14 @@ DEPENDENCIES:
- yoga (from `../node_modules/react-native/ReactCommon/yoga`)

SPEC REPOS:
https://github.com/cocoapods/specs.git:
- AppCenter
- AppCenterReactNativeShared
trunk:
- boost-for-react-native
- EFQRCode
- lottie-ios
- Sentry
- swift_qrcodejs

EXTERNAL SOURCES:
appcenter:
:path: "../node_modules/appcenter/ios"
appcenter-analytics:
:path: "../node_modules/appcenter-analytics/ios"
appcenter-crashes:
:path: "../node_modules/appcenter-crashes/ios"
BVLinearGradient:
:path: "../node_modules/react-native-linear-gradient"
DoubleConversion:
Expand Down Expand Up @@ -342,11 +313,6 @@ EXTERNAL SOURCES:
:path: "../node_modules/react-native/ReactCommon/yoga"

SPEC CHECKSUMS:
AppCenter: fddcbac6e4baae3d93a196ceb0bfe0e4ce407dec
appcenter: dc687dcf81280ccab1dc938b0b974d265144a802
appcenter-analytics: fa8dba207d07733dcbda749d262fde3e7161258d
appcenter-crashes: fa97ffec69882486d7183193cc9394473757d1ad
AppCenterReactNativeShared: d5e360f8a4cb5126d29e31ab98051d2f070ba631
boost-for-react-native: 39c7adb57c4e60d6c5479dd8623128eb5b3f0f2c
BVLinearGradient: 8cbc5155c978f2e43098818c91d206d07aae6d30
DoubleConversion: 5805e889d232975c086db112ece9ed034df7a0b2
Expand All @@ -364,12 +330,12 @@ SPEC CHECKSUMS:
React-jsinspector: e08662d1bf5b129a3d556eb9ea343a3f40353ae4
react-native-biometrics: c892904948a32295b128f633bcc11eda020645c5
react-native-blur: cad4d93b364f91e7b7931b3fa935455487e5c33c
react-native-camera: 203091b4bf99d48b788a0682ad573e8718724893
react-native-camera: f4f2144140ae1e808cad97cc7caf013767c11f1b
react-native-haptic-feedback: 22c9dc85fd8059f83bf9edd9212ac4bd4ae6074d
react-native-image-picker: 3637d63fef7e32a230141ab4660d3ceb773c824f
react-native-randombytes: 991545e6eaaf700b4ee384c291ef3d572e0b2ca8
react-native-slider: 6d83f7b8076a84e965a43fbdcfcf9dac19cea42e
react-native-webview: f72ac4078e115dfa741cc588acb1cca25566457d
react-native-image-picker: 7a85cf7b0a53845f03ae52fb4592a2748ded069b
react-native-randombytes: 3638d24759d67c68f6ccba60c52a7a8a8faa6a23
react-native-slider: 884693dd50f84745baa511ecdcde4c16f32182fb
react-native-webview: 2d8de2be422f0f8b9ba38db3f013f9ebfdb9b78f
React-RCTActionSheet: b0f1ea83f4bf75fb966eae9bfc47b78c8d3efd90
React-RCTAnimation: 359ba1b5690b1e87cc173558a78e82d35919333e
React-RCTBlob: 5e2b55f76e9a1c7ae52b826923502ddc3238df24
Expand All @@ -382,9 +348,9 @@ SPEC CHECKSUMS:
React-RCTWebSocket: cd932a16b7214898b6b7f788c8bddb3637246ac4
ReactNativePrivacySnapshot: cc295e45dc22810e9ff2c93380d643de20a77015
RemobileReactNativeQrcodeLocalImage: 57aadc12896b148fb5e04bc7c6805f3565f5c3fa
RNCAsyncStorage: 5ae4d57458804e99f73d427214442a6b10a53856
RNDefaultPreference: 12d246dd2222e66dadcd76cc1250560663befc3a
RNDeviceInfo: 12faae605ba42a1a5041c3c41a77834bc23f049d
RNCAsyncStorage: 44395cb9c7c1523104c2b499eb426ef7aff82bca
RNDefaultPreference: 628cb35719f2fe4111c000ccfa7e186400bbc47e
RNDeviceInfo: 687c1b2ab6d86ff1ca1208783320cd144138c7f2
RNFS: c9bbde46b0d59619f8e7b735991c60e0f73d22c1
RNGestureHandler: 5329a942fce3d41c68b84c2c2276ce06a696d8b0
RNHandoff: d3b0754cca3a6bcd9b25f544f733f7f033ccf5fa
Expand All @@ -396,12 +362,12 @@ SPEC CHECKSUMS:
RNSVG: 0eb087cfb5d7937be93c45b163b26352a647e681
RNVectorIcons: 0bb4def82230be1333ddaeee9fcba45f0b288ed4
RNWatch: a14e378448e187cc12f307f61d41fe8a65400e86
Sentry: bba998b0fb157fdd6596aa73290a9d67ae47be79
Sentry: 14bdd673870e8cf64932b149fad5bbbf39a9b390
swift_qrcodejs: 4d024fc98b0778b804ec6a5c810880fd092aec9d
TcpSockets: 8d839b9b14f6f344d98e4642ded13ab3112b462d
ToolTipMenu: bdcaa0e888bcf44778a67fe34639b094352e904e
TcpSockets: 14306fb79f9750ea7d2ddd02d8bed182abb01797
ToolTipMenu: 8ac61aded0fbc4acfe7e84a7d0c9479d15a9a382
yoga: 312528f5bbbba37b4dcea5ef00e8b4033fdd9411

PODFILE CHECKSUM: f93db402b02d7f01a8bc51d9b2cc10a39391b081
PODFILE CHECKSUM: 6e4becf6b95fb1241cd3ac1084da0a8cb3db7069

COCOAPODS: 1.7.5
COCOAPODS: 1.8.4
6 changes: 1 addition & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@
"prepare": "./patches/fix_mangle.sh; git apply patches/minifier.js.patch; git apply patches/minify.js.patch",
"clean": "cd android/; ./gradlew clean; cd ..; rm -r -f /tmp/metro-cache/; rm -r -f node_modules/; npm cache clean --force; npm i; npm start -- --reset-cache",
"releasenotes2json": "./release-notes.sh > release-notes.txt; node -e 'console.log(JSON.stringify(require(\"fs\").readFileSync(\"release-notes.txt\", \"utf8\")));' > release-notes.json",
"podinstall": "./podinstall.sh",
"start": "node node_modules/react-native/local-cli/cli.js start",
"android": "react-native run-android",
"ios": "react-native run-ios",
"postinstall": "./node_modules/.bin/rn-nodeify --install buffer,events,process,stream,util,inherits,fs,path --hack; npm run releasenotes2json; npm run podinstall; npx jetify",
"postinstall": "./node_modules/.bin/rn-nodeify --install buffer,events,process,stream,util,inherits,fs,path --hack; npm run releasenotes2json; npx jetify",
"test": "npm run unit && npm run jest && npm run lint",
"jest": "node node_modules/jest/bin/jest.js tests/integration/*",
"lint": "./node_modules/.bin/eslint *.js screen/**/*.js screen/ class/ models/ loc/ tests/integration/ --fix",
Expand All @@ -54,9 +53,6 @@
"@remobile/react-native-qrcode-local-image": "git+https://github.com/BlueWallet/react-native-qrcode-local-image.git",
"@sentry/react-native": "1.0.9",
"amplitude-js": "5.7.0",
"appcenter": "2.6.0",
"appcenter-analytics": "2.6.0",
"appcenter-crashes": "2.6.0",
"bech32": "1.1.3",
"bignumber.js": "9.0.0",
"bip21": "2.0.2",
Expand Down
9 changes: 0 additions & 9 deletions podinstall.sh

This file was deleted.

18 changes: 1 addition & 17 deletions react-native.config.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,3 @@
module.exports = {
dependencies: {
appcenter: {
platforms: {
android: null, // disable Android platform, other platforms will still autolink if provided
},
},
'appcenter-analytics': {
platforms: {
android: null, // disable Android platform, other platforms will still autolink if provided
},
},
'appcenter-crashes': {
platforms: {
android: null, // disable Android platform, other platforms will still autolink if provided
},
},
},
dependencies: {},
};
2 changes: 0 additions & 2 deletions screen/wallets/add.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import { HDSegwitP2SHWallet } from '../../class/hd-segwit-p2sh-wallet';
import { AppStorage, HDSegwitBech32Wallet, SegwitP2SHWallet } from '../../class';
import ReactNativeHapticFeedback from 'react-native-haptic-feedback';
let EV = require('../../events');
let A = require('../../analytics');
/** @type {AppStorage} */
let BlueApp = require('../../BlueApp');
let loc = require('../../loc');
Expand Down Expand Up @@ -179,7 +178,6 @@ export default class WalletsAdd extends Component {
BlueApp.wallets.push(w);
await BlueApp.saveToDisk();
EV(EV.enum.WALLETS_COUNT_CHANGED);
A(A.ENUM.CREATED_WALLET);
ReactNativeHapticFeedback.trigger('notificationSuccess', { ignoreAndroidSystemSettings: false });
if (w.type === HDSegwitP2SHWallet.type || w.type === HDSegwitBech32Wallet.type) {
this.props.navigation.navigate('PleaseBackup', {
Expand Down
2 changes: 0 additions & 2 deletions screen/wallets/import.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import PropTypes from 'prop-types';
import ReactNativeHapticFeedback from 'react-native-haptic-feedback';
import Privacy from '../../Privacy';
let EV = require('../../events');
let A = require('../../analytics');
/** @type {AppStorage} */
let BlueApp = require('../../BlueApp');
let loc = require('../../loc');
Expand Down Expand Up @@ -66,7 +65,6 @@ export default class WalletsImport extends Component {
BlueApp.wallets.push(w);
await BlueApp.saveToDisk();
EV(EV.enum.WALLETS_COUNT_CHANGED);
A(A.ENUM.CREATED_WALLET);
this.props.navigation.dismiss();
}
}
Expand Down
Loading

0 comments on commit 0d7d85c

Please sign in to comment.