Socket
Socket
Sign inDemoInstall

@sentry/webpack-plugin

Package Overview
Dependencies
Maintainers
13
Versions
98
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sentry/webpack-plugin - npm Package Compare versions

Comparing version 1.11.1 to 1.12.0

src/cjs.js

7

CHANGELOG.md
# Changelog
## v1.12.0
- feat: Allow to perform release deploys (#192)
- fix: CJS/TS Exports Interop (#190)
- fix: make setCommits.repo type optional (#200)
- deps: Bump sentry-cli to `1.55.0`
## v1.11.1

@@ -4,0 +11,0 @@

4

index.d.ts

@@ -123,7 +123,9 @@ import { Plugin, Compiler } from 'webpack';

* The full repo name as defined in Sentry.
* Required if auto option is not true.
*/
repo: string;
repo?: string;
/**
* The current (last) commit in the release.
* Required if auto option is not true.
*/

@@ -130,0 +132,0 @@ commit?: string;

@@ -11,7 +11,7 @@ {

"author": "Sentry",
"version": "1.11.1",
"version": "1.12.0",
"license": "MIT",
"repository": "git@github.com:getsentry/sentry-webpack-plugin.git",
"homepage": "https://github.com/getsentry/sentry-webpack-plugin",
"main": "src/index.js",
"main": "src/cjs.js",
"types": "index.d.ts",

@@ -22,3 +22,3 @@ "engines": {

"dependencies": {
"@sentry/cli": "^1.52.3"
"@sentry/cli": "^1.55.0"
},

@@ -25,0 +25,0 @@ "devDependencies": {

@@ -84,2 +84,3 @@ <p align="center">

| setCommits | `Object` | optional | Adds commits to sentry - [see own table below](#setCommits) for more details |
| deploy | `Object` | optional | Creates a new release deployment - [see own table below](#deploy) for more details |

@@ -91,8 +92,19 @@

---------|------|----------|-------------
| repo | `string` | required | the full git repo name as defined in Sentry |
| commit | `string` | optional/required | the current (last) commit in the release |
| repo | `string` | optional/required | the full git repo name as defined in Sentry. Required if `auto` option is not `true`. |
| commit | `string` | optional/required | the current (last) commit in the release. Required if `auto` option is not `true`. |
| previousCommit | `string` | optional | the commit before the beginning of this release (in other words, the last commit of the previous release). If omitted, this will default to the last commit of the previous release in Sentry. If there was no previous release, the last 10 commits will be used |
| auto | `boolean` | optional/required | automatically choose the associated commit (uses the current commit). Overrides other options |
| auto | `boolean` | optional | automatically choose the associated commit (uses the current commit). Overrides other options |
#### <a name="deploy"></a>options.deploy:
| Option | Type | Required | Description |
---------|------|----------|-------------
| env | `string` | required | environment for this release. Values that make sense here would be `production` or `staging` |
| started | `number` | optional | unix timestamp when the deployment started |
| finished | `number` | optional | unix timestamp when the deployment finished |
| time | `number` | optional | deployment duration in seconds. This can be specified alternatively to `started` and `finished` |
| name | `string` | optional | human readable name for this deployment |
| url | `string` | optional | URL that points to the deployment |
You can find more information about these options in our official docs:
https://docs.sentry.io/cli/releases/#sentry-cli-sourcemaps

@@ -18,3 +18,3 @@ /*eslint-disable*/

const SentryCli = jest.mock('@sentry/cli', () => SentryCliMock);
const SentryCliPlugin = require('..');
const SentryCliPlugin = require('../..');

@@ -21,0 +21,0 @@ afterEach(() => {

@@ -157,2 +157,6 @@ const SentryCli = require('@sentry/cli');

},
deploy: (release, config) => {
this.outputDebug('Calling deploy with:\n', config);
return Promise.resolve(release, config);
},
},

@@ -338,3 +342,3 @@ };

if (auto || (repo && commit)) {
this.cli.releases.setCommits(release, {
return this.cli.releases.setCommits(release, {
commit,

@@ -346,2 +350,4 @@ previousCommit,

}
return undefined;
})

@@ -354,2 +360,18 @@ .then(() => {

})
.then(() => {
const { env, started, finished, time, name, url } =
this.options.deploy || {};
if (env) {
return this.cli.releases.newDeploy(release, {
env,
started,
finished,
time,
name,
url,
});
}
return undefined;
})
.catch(err =>

@@ -381,2 +403,2 @@ errorHandler(

module.exports = SentryCliPlugin;
module.exports.default = SentryCliPlugin;
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc