Skip to content

Commit 1d58d21

Browse files
author
alexlee-dev
committed
🐛 Add Sentry
1 parent 13bbd4f commit 1d58d21

3 files changed

Lines changed: 131 additions & 0 deletions

File tree

package-lock.json

Lines changed: 123 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
"typescript": "^3.9.3"
4444
},
4545
"dependencies": {
46+
"@sentry/node": "^5.15.5",
4647
"boxen": "^4.2.0",
4748
"chalk": "^4.0.0",
4849
"clear": "^0.1.0",

src/index.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
import chalk from "chalk";
22
import commander from "commander";
3+
import * as Sentry from "@sentry/node";
4+
5+
Sentry.init({
6+
dsn:
7+
"https://55c913cc3d394f71ba669fda095698fd@o202486.ingest.sentry.io/5254191",
8+
});
39

410
import {
511
copyTemplateFiles,
@@ -54,6 +60,7 @@ const main = async (): Promise<void> => {
5460
} catch (error) {
5561
// TODO - Cleanup
5662
console.error(error);
63+
throw new Error(error);
5764
}
5865
};
5966

0 commit comments

Comments
 (0)