Some sentry updates

This commit is contained in:
Gregory Schier 2016-08-17 12:12:13 -07:00
parent 6bbdcaf440
commit 2bdeb76bd0
2 changed files with 35 additions and 10 deletions

View File

@ -19,16 +19,29 @@
levels: ['warn', 'error'], levels: ['warn', 'error'],
release: require('./app.json').version, release: require('./app.json').version,
environment: process.env.NODE_ENV, environment: process.env.NODE_ENV,
ignoreErrors: [ ignoreUrls: [
'fb_xd_fragment', /.*raven\.min\.js.*/
/ReferenceError:.*/
],
excludePaths: [
/\/external\/.*/
], ],
includePaths: [ includePaths: [
/.*/ /^(?!.*raven.min.js$).*$/ // Ignore raven stuff
] ],
dataCallback: function (data) {
console.log("SENTRY DATA", data);
var normalize = function (filename) {
var match = filename.match(/\/(app.asar|build)\/(.*)/);
if (match) {
return match[2]; // return everything after ../app.asar/*
} else {
return filename;
}
};
data.exception.values[0].stacktrace.frames.forEach(function (frame) {
frame.filename = normalize(frame.filename);
});
return data
}
}).install(); }).install();
console.log('-- Initialized Sentry --'); console.log('-- Initialized Sentry --');

View File

@ -6,7 +6,10 @@ SENTRY_TOKEN="367a6d824c8449bfbff884f0c1bc6180"
echo "-- Creating Release $APP_VERSION --" echo "-- Creating Release $APP_VERSION --"
# Create a new release # ~~~~~~~~~~~~~~~~~~~~ #
# Create a new release #
# ~~~~~~~~~~~~~~~~~~~~ #
curl https://app.getsentry.com/api/0/projects/schierco/insomnia-electron/releases/ \ curl https://app.getsentry.com/api/0/projects/schierco/insomnia-electron/releases/ \
-X POST \ -X POST \
-u "$SENTRY_TOKEN:" \ -u "$SENTRY_TOKEN:" \
@ -16,7 +19,16 @@ curl https://app.getsentry.com/api/0/projects/schierco/insomnia-electron/release
echo "" echo ""
echo "-- Uploading Source Maps for $APP_VERSION --" echo "-- Uploading Source Maps for $APP_VERSION --"
# Upload a file for the given release # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #
# Upload files for the given release #
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #
curl https://app.getsentry.com/api/0/projects/schierco/insomnia-electron/releases/${APP_VERSION}/files/ \
-X POST \
-u "$SENTRY_TOKEN:" \
-F file=@./build/bundle.js \
-F name="bundle.js"
curl https://app.getsentry.com/api/0/projects/schierco/insomnia-electron/releases/${APP_VERSION}/files/ \ curl https://app.getsentry.com/api/0/projects/schierco/insomnia-electron/releases/${APP_VERSION}/files/ \
-X POST \ -X POST \
-u "$SENTRY_TOKEN:" \ -u "$SENTRY_TOKEN:" \