Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@sentry/cli

Package Overview
Dependencies
Maintainers
11
Versions
231
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sentry/cli - npm Package Compare versions

Comparing version 2.21.5 to 2.22.1

18

checksums.txt

@@ -1,9 +0,9 @@

sentry-cli-Darwin-arm64=e142beae033d0cbd04b27678be9a5c5ea1ec03fc3f385055088f5e9606077a5f
sentry-cli-Darwin-universal=bf3cbc83ed490f4bc4a75627f509a76f3d584ed16a539cd0aa9d9673d389e8a9
sentry-cli-Darwin-x86_64=88bda5b074b896f557ac7eb23442bf53d4c2085c478d6bf6464821ff2463bda6
sentry-cli-Linux-aarch64=74838d45d7915f1c9bc08b262a7cc57da8b1d597faa7d754aab4be8eb7af8e17
sentry-cli-Linux-armv7=297373be79b59c843cea7a061b8fea5effb1707dacf8c6eb3140d8c09363676e
sentry-cli-Linux-i686=45038805edf469c20f9b1fcc5d2185aafe6c3f9540223265b8a78a0054742e0a
sentry-cli-Linux-x86_64=6027f652fc3f9ad17a8b20df027d78dc458a1747db33657a4df0d9c9ba6d2ccd
sentry-cli-Windows-i686.exe=265a9bdcbf91cfc5453fb3f67762e9ebd5a8675af92b9bad7816cdbc637248f1
sentry-cli-Windows-x86_64.exe=38ca36c244c6a45e27f4b5a914b2b1eaa99b502972c630a8fec4473f053e76e4
sentry-cli-Darwin-arm64=744dfe9b9502c4c3a35a224838a1bce7db0132c122f8615417cc9d32217f7fa9
sentry-cli-Darwin-universal=508f76bd7ce43cdbab9e0b2ce068917ef95c0ea9c5a57ddd5546f95f8cdd8a3b
sentry-cli-Darwin-x86_64=a16caaa9fc7405ba50aed5d576042ee1c3a91eee13d2b1da0f59fd9dec665655
sentry-cli-Linux-aarch64=c7ed4c6586692ed56ce84db202aa5e5dee48e5d56dcd45b42b45eb5384dcbffa
sentry-cli-Linux-armv7=aa69ed00523ead7448dddb679e0c5a0f599a5808adff5205cb1397e1004f3203
sentry-cli-Linux-i686=d8aeee45ae41a104d2cb1586eca953dbd697a6d1c92cb00ef45e3bf7c31bc70c
sentry-cli-Linux-x86_64=0a34cf9b3d3069b7a5c816650fa9cf07963ccc77e881629a6ed82db9727bdf91
sentry-cli-Windows-i686.exe=fe57cc17abcf8bd50f6ded08dc36fc723a5a2ddfd93dbc18edaf00856d6bfa36
sentry-cli-Windows-x86_64.exe=49ae8dfa38d11d234c9816001e3c1af0741e780860eebaf89a971c8c6f49c7f4
'use strict';
const os = require('os');
const path = require('path');
const childProcess = require('child_process');
const BINARY_DISTRIBUTIONS = [
{ packageName: '@sentry/cli-darwin', subpath: 'bin/sentry-cli' },
{ packageName: '@sentry/cli-linux-x64', subpath: 'bin/sentry-cli' },
{ packageName: '@sentry/cli-linux-i686', subpath: 'bin/sentry-cli' },
{ packageName: '@sentry/cli-linux-arm64', subpath: 'bin/sentry-cli' },
{ packageName: '@sentry/cli-linux-arm', subpath: 'bin/sentry-cli' },
{ packageName: '@sentry/cli-win32-x64', subpath: 'bin/sentry-cli.exe' },
{ packageName: '@sentry/cli-win32-i686', subpath: 'bin/sentry-cli.exe' },
];
function getDistributionForThisPlatform() {
const arch = os.arch();
const platform = os.platform();
let packageName = undefined;
if (platform === 'darwin') {
packageName = '@sentry/cli-darwin';
} else if (platform === 'linux' || platform === 'freebsd') {
switch (arch) {
case 'x64':
packageName = '@sentry/cli-linux-x64';
break;
case 'x86':
case 'ia32':
packageName = '@sentry/cli-linux-i686';
break;
case 'arm64':
packageName = '@sentry/cli-linux-arm64';
break;
case 'arm':
packageName = '@sentry/cli-linux-arm';
break;
}
} else if (platform === 'win32') {
switch (arch) {
case 'x64':
packageName = '@sentry/cli-win32-x64';
break;
case 'x86':
case 'ia32':
packageName = '@sentry/cli-win32-i686';
break;
}
}
let subpath = undefined;
switch (platform) {
case 'win32':
subpath = 'bin/sentry-cli.exe';
break;
case 'darwin':
case 'linux':
case 'freebsd':
subpath = 'bin/sentry-cli';
break;
default:
subpath = 'bin/sentry-cli';
break;
}
return { packageName, subpath };
}
/**

@@ -19,7 +83,51 @@ * This convoluted function resolves the path to the `sentry-cli` binary in a

const parts = [];
parts.push(__dirname);
parts.push('..');
parts.push(`sentry-cli${process.platform === 'win32' ? '.exe' : ''}`);
return path.resolve(...parts);
if (!process.env.USE_SENTRY_BINARY_NPM_DISTRIBUTION) {
const parts = [];
parts.push(__dirname);
parts.push('..');
parts.push(`sentry-cli${process.platform === 'win32' ? '.exe' : ''}`);
return path.resolve(...parts);
}
const { packageName, subpath } = getDistributionForThisPlatform();
if (packageName === undefined) {
throw new Error(
`Unsupported operating system or architecture! Sentry CLI does not work on this architecture.
Sentry CLI supports:
- Darwin (macOS)
- Linux and FreeBSD on x64, x86, ia32, arm64, and arm architectures
- Windows x64, x86, and ia32 architectures`
);
}
let compatibleBinaryPath;
try {
compatibleBinaryPath = require.resolve(`${packageName}/${subpath}`);
} catch (e) {
const otherInstalledDistribution = BINARY_DISTRIBUTIONS.find(({ packageName, subpath }) => {
try {
require.resolve(`${packageName}/${subpath}`);
return true;
} catch (e) {
return false;
}
});
// These error messages are heavily inspired by esbuild's error messages: https://github.com/evanw/esbuild/blob/f3d535262e3998d845d0f102b944ecd5a9efda57/lib/npm/node-platform.ts#L150
if (otherInstalledDistribution) {
throw new Error(`Sentry CLI binary for this platform/architecture not found!
The "${otherInstalledDistribution.packageName}" package is installed, but for the current platform, you should have the "${packageName}" package installed instead. This usually happens if the "@sentry/cli" package is installed on one platform (for example Windows or MacOS) and then the "node_modules" folder is reused on another operating system (for example Linux in Docker).
To fix this, avoid copying the "node_modules" folder, and instead freshly install your dependencies on the target system. You can also configure your package manager to install the right package. For example, yarn has the "supportedArchitectures" feature: https://yarnpkg.com/configuration/yarnrc/#supportedArchitecture.`);
} else {
throw new Error(`Sentry CLI binary for this platform/architecture not found!
It seems like none of the "@sentry/cli" package's optional dependencies got installed. Please make sure your package manager is configured to install optional dependencies. If you are using npm to install your dependencies, please don't set the "--no-optional" or "--omit=optional" flags. Sentry CLI needs the "optionalDependencies" feature in order to install its binary.`);
}
}
return compatibleBinaryPath;
}

@@ -26,0 +134,0 @@

{
"name": "@sentry/cli",
"version": "2.21.5",
"version": "2.22.1",
"description": "A command line utility to work with Sentry. https://docs.sentry.io/hosted/learn/cli/",

@@ -32,2 +32,11 @@ "repository": "git://github.com/getsentry/sentry-cli.git",

},
"optionalDependencies": {
"@sentry/cli-darwin": "2.22.1",
"@sentry/cli-linux-arm": "2.22.1",
"@sentry/cli-linux-arm64": "2.22.1",
"@sentry/cli-linux-i686": "2.22.1",
"@sentry/cli-linux-x64": "2.22.1",
"@sentry/cli-win32-i686": "2.22.1",
"@sentry/cli-win32-x64": "2.22.1"
},
"scripts": {

@@ -34,0 +43,0 @@ "install": "node ./scripts/install.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc