@sentry/bundler-plugin-core
Advanced tools
Comparing version 0.4.0 to 0.5.0
import { Options } from "./types"; | ||
import "@sentry/tracing"; | ||
export declare function getBuildInformation(): { | ||
deps: string[]; | ||
depsVersions: Record<string, number>; | ||
nodeVersion: number | undefined; | ||
}; | ||
/** | ||
* Determines whether the Sentry CLI binary is in its expected location. | ||
* This function is useful since `@sentry/cli` installs the binary via a post-install | ||
* script and post-install scripts may not always run. E.g. with `npm i --ignore-scripts`. | ||
*/ | ||
export declare function sentryCliBinaryExists(): boolean; | ||
export declare const sentryVitePlugin: (options: Options) => any; | ||
@@ -4,0 +15,0 @@ export declare const sentryRollupPlugin: (options: Options) => any; |
import { Logger } from "./sentry/logger"; | ||
import { IncludeEntry as UserIncludeEntry, Options as UserOptions } from "./types"; | ||
declare type RequiredInternalOptions = Required<Pick<UserOptions, "finalize" | "dryRun" | "debug" | "silent" | "cleanArtifacts" | "telemetry" | "injectReleasesMap">>; | ||
declare type RequiredInternalOptions = Required<Pick<UserOptions, "finalize" | "dryRun" | "debug" | "silent" | "cleanArtifacts" | "telemetry" | "injectReleasesMap" | "_experiments" | "injectRelease" | "uploadSourceMaps">>; | ||
declare type OptionalInternalOptions = Partial<Pick<UserOptions, "org" | "project" | "authToken" | "url" | "vcsRemote" | "dist" | "errorHandler" | "setCommits" | "deploy" | "configFile" | "headers">>; | ||
@@ -5,0 +5,0 @@ declare type NormalizedInternalOptions = { |
@@ -6,4 +6,5 @@ import { InternalOptions } from "../options-mapping"; | ||
export declare function uploadSourceMaps(options: InternalOptions, ctx: BuildContext, releaseName: string): Promise<void>; | ||
export declare function uploadDebugIdSourcemaps(options: InternalOptions, ctx: BuildContext, folderPathToUpload: string, releaseName: string): Promise<void>; | ||
export declare function setCommits(options: InternalOptions, ctx: BuildContext, releaseName: string): Promise<void>; | ||
export declare function finalizeRelease(options: InternalOptions, ctx: BuildContext, releaseName: string): Promise<void>; | ||
export declare function addDeploy(options: InternalOptions, ctx: BuildContext, releaseName: string): Promise<void>; |
@@ -165,2 +165,8 @@ import { Hub } from "@sentry/core"; | ||
/** | ||
* Whether the plugin should inject release information into the build. | ||
* | ||
* Defaults to `true`. | ||
*/ | ||
injectRelease?: boolean; | ||
/** | ||
* If set to true, the plugin will inject an additional `SENTRY_RELEASES` variable that | ||
@@ -173,2 +179,37 @@ * maps from `{org}@{project}` to the `release` value. This might be helpful for webpack | ||
injectReleasesMap?: boolean; | ||
/** | ||
* Whether the plugin should upload source maps to Sentry. | ||
* | ||
* Defaults to `true`. | ||
*/ | ||
uploadSourceMaps?: boolean; | ||
/** | ||
* Options that are considered experimental and subject to change. | ||
*/ | ||
_experiments?: { | ||
/** | ||
* If set to true, the plugin will inject an additional `SENTRY_BUILD_INFO` variable. | ||
* This contains information about the build, e.g. dependencies, node version and other useful data. | ||
* | ||
* Defaults to `false`. | ||
*/ | ||
injectBuildInformation?: boolean; | ||
/** | ||
* Configuration for debug ID upload. | ||
* | ||
* Note: Currently only functional for Vite and Rollup. | ||
*/ | ||
debugIdUpload?: { | ||
/** | ||
* Glob paths to files that should get be injected with a debug ID and uploaded. | ||
*/ | ||
include: string | string[]; | ||
/** | ||
* Glob paths to files that should be ignored for debug ID injection and upload. | ||
* | ||
* Default: `[]` | ||
*/ | ||
ignore?: string | string[]; | ||
}; | ||
}; | ||
}; | ||
@@ -175,0 +216,0 @@ export declare type IncludeEntry = { |
@@ -8,1 +8,22 @@ /** | ||
export declare function arrayify<T = unknown>(maybeArray: T | T[]): T[]; | ||
declare type PackageJson = Record<string, unknown>; | ||
/** | ||
* Get the closes package.json from a given starting point upwards. | ||
* This handles a few edge cases: | ||
* * Check if a given file package.json appears to be an actual NPM package.json file | ||
* * Stop at the home dir, to avoid looking too deeply | ||
*/ | ||
export declare function getPackageJson({ cwd, stopAt }?: { | ||
cwd?: string; | ||
stopAt?: string; | ||
}): PackageJson | undefined; | ||
export declare function parseMajorVersion(version: string): number | undefined; | ||
export declare function getDependencies(packageJson: PackageJson): { | ||
deps: string[]; | ||
depsVersions: Record<string, number>; | ||
}; | ||
/** | ||
* Deterministically hashes a string and turns the hash into a uuid. | ||
*/ | ||
export declare function stringToUUID(str: string): string; | ||
export {}; |
{ | ||
"name": "@sentry/bundler-plugin-core", | ||
"version": "0.4.0", | ||
"version": "0.5.0", | ||
"description": "Sentry Bundler Plugin Core", | ||
@@ -13,10 +13,5 @@ "repository": "git://github.com/getsentry/sentry-javascript-bundler-plugins.git", | ||
"files": [ | ||
"dist" | ||
"dist", | ||
"sentry-release-injection-file.js" | ||
], | ||
"exports": { | ||
".": { | ||
"import": "./dist/esm/index.mjs", | ||
"require": "./dist/cjs/index.js" | ||
} | ||
}, | ||
"main": "dist/cjs/index.js", | ||
@@ -45,5 +40,7 @@ "module": "dist/esm/index.mjs", | ||
"dependencies": { | ||
"@sentry/cli": "^2.10.0", | ||
"@sentry/cli": "^2.17.0", | ||
"@sentry/node": "^7.19.0", | ||
"@sentry/tracing": "^7.19.0", | ||
"find-up": "5.0.0", | ||
"glob": "9.3.2", | ||
"magic-string": "0.27.0", | ||
@@ -61,4 +58,4 @@ "unplugin": "1.0.1" | ||
"@rollup/plugin-replace": "^4.0.0", | ||
"@sentry-internal/eslint-config": "0.4.0", | ||
"@sentry-internal/sentry-bundler-plugin-tsconfig": "0.4.0", | ||
"@sentry-internal/eslint-config": "0.5.0", | ||
"@sentry-internal/sentry-bundler-plugin-tsconfig": "0.5.0", | ||
"@swc/core": "^1.2.205", | ||
@@ -65,0 +62,0 @@ "@swc/jest": "^0.2.21", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
533303
17
5145
7
12
+ Addedfind-up@5.0.0
+ Addedglob@9.3.2
+ Addedbalanced-match@1.0.2(transitive)
+ Addedbrace-expansion@2.0.1(transitive)
+ Addedfind-up@5.0.0(transitive)
+ Addedfs.realpath@1.0.0(transitive)
+ Addedglob@9.3.2(transitive)
+ Addedlocate-path@6.0.0(transitive)
+ Addedlru-cache@10.4.3(transitive)
+ Addedminimatch@7.4.6(transitive)
+ Addedminipass@4.2.87.1.2(transitive)
+ Addedp-limit@3.1.0(transitive)
+ Addedp-locate@5.0.0(transitive)
+ Addedpath-exists@4.0.0(transitive)
+ Addedpath-scurry@1.11.1(transitive)
+ Addedyocto-queue@0.1.0(transitive)
Updated@sentry/cli@^2.17.0