Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Use sentry-wizard instead of custom postlink/unlink scripts #306

Merged
merged 21 commits into from
Dec 4, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ branches:
only:
- master

before_install:
- curl -o- -L https://yarnpkg.com/install.sh | bash
- export PATH="$HOME/.yarn/bin:$PATH"

matrix:
include:
- language: node_js
Expand Down Expand Up @@ -44,7 +48,10 @@ matrix:
- pip
- yarn
env: LANE='ios'
before_install: .travis/before_install.sh
before_install:
- curl -o- -L https://yarnpkg.com/install.sh | bash
- export PATH="$HOME/.yarn/bin:$PATH"
- .travis/before_install.sh
before_script:
- sudo easy_install virtualenv
- virtualenv ~/virtualenv
Expand All @@ -54,6 +61,7 @@ matrix:
- language: node_js
node_js: 8
script: .travis/deploy.sh
env: LANE='deploy'
after_success:
- npm install -g @zeus-ci/cli
- zeus upload -t "application/tar+npm" *.tgz
Expand Down
6 changes: 2 additions & 4 deletions .travis/before_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ set -e
if [ "$LANE" = "ios" ]; then
brew update
brew install yarn
brew outdated node || brew upgrade node
brew outdated yarn || brew upgrade yarn
elif [ "$LANE" = "android" ]; then
node --version
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update -qq
sudo apt-get install -y -qq yarn
npm install -g yarn
fi
2 changes: 1 addition & 1 deletion .travis/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set -e
if [ "$LANE" = "node" ]; then
yarn install
npm run test-typescript
npm run test:typescript

cd appium
npm install -g react-native-cli
Expand Down
10 changes: 5 additions & 5 deletions lib/raven-plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -183,11 +183,11 @@ function reactNativePlugin(Raven, options, internalDataCallback) {
*/
reactNativePlugin._persistPayload = function(payload) {
var AsyncStorage = require('react-native').AsyncStorage;
return AsyncStorage.setItem(ASYNC_STORAGE_KEY, JSON.stringify(payload))[
'catch'
](function() {
return null;
});
return AsyncStorage.setItem(ASYNC_STORAGE_KEY, JSON.stringify(payload))['catch'](
function() {
return null;
}
);
};

/**
Expand Down
13 changes: 5 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"preversion:changelog": "grep -q -F \"## v$npm_package_version\" CHANGELOG.md",
"version": "npm run preversion:changelog && node ./scripts/version-bump.js && git add -A",
"precommit": "lint-staged",
"test-typescript": "node_modules/typescript/bin/tsc --noImplicitAny --allowJs typescript/Sentry-tests.ts"
"test:typescript": "node_modules/typescript/bin/tsc --noImplicitAny --allowJs typescript/Sentry-tests.ts"
},
"keywords": [
"react-native",
Expand All @@ -25,17 +25,14 @@
"react-native": ">=0.38.0"
},
"dependencies": {
"chalk": "^2.3.0",
"glob": "^7.1.1",
"inquirer": "^3.3.0",
"raven-js": "^3.19.1",
"sentry-cli-binary": "^1.21.0",
"xcode": "^1.0.0"
"@sentry/wizard": "^0.6.0",
"sentry-cli-binary": "^1.21.0"
},
"rnpm": {
"commands": {
"postlink": "node node_modules/react-native-sentry/scripts/postlink.js",
"postunlink": "node node_modules/react-native-sentry/scripts/postunlink.js"
"postlink": "node node_modules/@sentry/wizard/dist/bin.js -t reactNative -p ios android",
"postunlink": "node node_modules/@sentry/wizard/dist/bin.js -t reactNative -p ios android --uninstall"
},
"android": {
"packageInstance": "new RNSentryPackage(MainApplication.this)"
Expand Down
Loading