Skip to content

Commit 03edd6d

Browse files
meta(readme): Modernize README, point users to docs (#3023)
While preparing to make some changes to the README for the 3.0 release, I noticed the README contains some outdated information. As much of this info is already available in a more updated state on https://docs.sentry.io/cli/, let's direct folks over there. Also, this change removes the badges (which contain info available elsewhere on the GitHub page) and updates first section of the README with a more up-to-date intro to Sentry CLI.
1 parent 80151e3 commit 03edd6d

File tree

1 file changed

+5
-117
lines changed

1 file changed

+5
-117
lines changed

README.md

Lines changed: 5 additions & 117 deletions
Original file line numberDiff line numberDiff line change
@@ -8,127 +8,15 @@
88
</a>
99
</p>
1010

11-
# Official Sentry Command Line Interface
11+
# Sentry CLI
1212

13-
[![Build Status](https://github.com/getsentry/sentry-cli/workflows/CI/badge.svg?branch=master)](https://github.com/getsentry/sentry-cli/actions?query=workflow%3ACI)
14-
[![GitHub release](https://img.shields.io/github/release/getsentry/sentry-cli.svg)](https://github.com/getsentry/sentry-cli/releases/latest)
15-
[![npm version](https://img.shields.io/npm/v/@sentry/cli.svg)](https://www.npmjs.com/package/@sentry/cli)
16-
[![license](https://img.shields.io/github/license/getsentry/sentry-cli.svg)](https://github.com/getsentry/sentry-cli/blob/master/LICENSE)
13+
This is the repository for Sentry CLI, the official command line interface for Sentry.
1714

18-
This is a Sentry command line client for some generic tasks. Right now this is
19-
primarily used to upload debug symbols to Sentry if you are not using the
20-
Fastlane tools.
15+
Sentry CLI can be used for many tasks, including uploading debug symbols and source maps to Sentry, managing releases, and viewing Sentry data such as issues and logs.
2116

22-
* Downloads can be found under
23-
[Releases](https://github.com/getsentry/sentry-cli/releases/)
24-
* Documentation can be found [here](https://docs.sentry.io/hosted/learn/cli/)
17+
## Installation and Usage
2518

26-
## Installation
27-
28-
If you are on macOS or Linux, you can use the automated downloader which will fetch the latest release version for you and install it:
29-
30-
curl -sL https://sentry.io/get-cli/ | bash
31-
32-
We do, however, encourage you to pin the specific version of the CLI, so your builds are always reproducible.
33-
To do that, you can use the exact same method, with an additional version specifier:
34-
35-
curl -sL https://sentry.io/get-cli/ | SENTRY_CLI_VERSION=2.33.1 bash
36-
37-
This will automatically download the correct version of `sentry-cli` for your operating system and install it. If necessary, it will prompt for your admin password for `sudo`. For a different installation location or for systems without `sudo` (like Windows), you can `export INSTALL_DIR=/custom/installation/path` before running this command.
38-
39-
If you are using `sentry-cli` on Windows environments, [Microsoft Visual C++ Redistributable](https://learn.microsoft.com/en-us/cpp/windows/latest-supported-vc-redist) is required.
40-
41-
To verify it’s installed correctly you can bring up the help:
42-
43-
sentry-cli --help
44-
45-
### pip
46-
47-
_New in 2.14.3_: `sentry-cli` can also be installed using `pip`:
48-
49-
```bash
50-
pip install sentry-cli
51-
```
52-
53-
### Node
54-
55-
Additionally, you can also install this binary via npm:
56-
57-
npm install @sentry/cli
58-
59-
When installing globally, make sure to have set
60-
[correct permissions on the global node_modules directory](https://docs.npmjs.com/getting-started/fixing-npm-permissions).
61-
If this is not possible in your environment or still produces an EACCESS error,
62-
install as root:
63-
64-
sudo npm install -g @sentry/cli --unsafe-perm
65-
66-
By default, this package will download sentry-cli from the CDN managed by [Fastly](https://www.fastly.com/).
67-
To use a custom CDN, set the npm config property `sentrycli_cdnurl`. The downloader will append
68-
`"/<version>/sentry-cli-<dist>"`.
69-
70-
```sh
71-
npm install @sentry/cli --sentrycli_cdnurl=https://mymirror.local/path
72-
```
73-
74-
Or add property into your `.npmrc` file (https://www.npmjs.org/doc/files/npmrc.html)
75-
76-
```rc
77-
sentrycli_cdnurl=https://mymirror.local/path
78-
```
79-
80-
There are a few environment variables that you can provide to control the npm installation:
81-
82-
```
83-
SENTRYCLI_CDNURL=<url> # Use alternative cdn url for downloading binary
84-
SENTRYCLI_USE_LOCAL=1 # Use local instance of sentry-cli binary (looked up via $PATH environment)
85-
SENTRYCLI_SKIP_DOWNLOAD=1 # Skip downloading binary entirely
86-
SENTRYCLI_NO_PROGRESS_BAR=1 # Do not print the progress bar when downloading binary (default for non-TTY environments like CI)
87-
SENTRYCLI_LOG_STREAM=<stdout|stderr> # Changes where to redirect install script output
88-
```
89-
90-
When using `sentry-cli` via JavaScript API or any 3rd party plugin that is consuming said API,
91-
you can also use `SENTRY_BINARY_PATH=<path>` alongside `SENTRYCLI_SKIP_DOWNLOAD=1` to completely
92-
control what binaries are downloaded and used throughout the whole process.
93-
94-
If you're installing the CLI with NPM from behind a proxy, the install script will
95-
use either NPM's configured HTTPS proxy server or the value from your `HTTPS_PROXY`
96-
environment variable.
97-
98-
### Homebrew
99-
100-
A homebrew recipe is provided in the `getsentry/tools` tap:
101-
102-
brew install getsentry/tools/sentry-cli
103-
104-
### Docker
105-
106-
As of version _1.25.0_, there is an official Docker image that comes with
107-
`sentry-cli` preinstalled. If you prefer a specific version, specify it as tag.
108-
The latest development version is published under the `edge` tag. In production,
109-
we recommend you to use the `latest` tag. To use it, run:
110-
111-
```sh
112-
docker pull getsentry/sentry-cli
113-
docker run --rm -v $(pwd):/work getsentry/sentry-cli --help
114-
```
115-
116-
Starting version _`2.8.0`_, in case you see `"error: config value 'safe.directory' was not found;"` message,
117-
you also need to correctly set UID and GID of mounted volumes like so:
118-
119-
```sh
120-
docker run --rm -u "$(id -u):$(id -g)" -v $(pwd):/work getsentry/sentry-cli --help
121-
```
122-
123-
This is required due to security issue in older `git` implementations. See [here](https://github.blog/2022-04-12-git-security-vulnerability-announced/) for more details.
124-
125-
## Update
126-
127-
To update sentry-cli to the latest version run:
128-
129-
```sh
130-
sentry-cli update
131-
```
19+
Please refer to [Sentry CLI's documentation page](https://docs.sentry.io/cli/).
13220

13321
## Compiling
13422

0 commit comments

Comments
 (0)