Dashboard › cli › Distillation
ad74ba35-2a95-4ece-b3ab-5cd7e8622bf2["lore_tm_v1_nfS3L34-7-Lh1XHcO11yYvqGTwDMN_PS9dHytgZS2Xc","lore_tm_v1_J-3SFquWNUNYndcV2aPkDJ8vdjuDNsZePC94mwB11cE"]
packages/cli/src/lib/binary.ts states that trailing path separators are stripped, but never from a bare root like /.packages/cli/src/lib/binary.ts states that a caller receives the successful probe response so it never repeats the successful probe/request.packages/cli/src/lib/binary.ts is the shared binary-management module used by both setup --install for fresh installs and upgrade for self-updates.packages/cli/src/lib/binary.ts imports synchronous filesystem operations existsSync, mkdirSync, readFileSync, renameSync, unlinkSync, and writeFileSync; promise-based operations chmod, copyFile, mkdir, realpath, and unlink; path helpers delimiter, dirname, isAbsolute, join, resolve, and sep; spawnSync; and semver compare as semverCompare.packages/cli/src/lib/binary.ts exports LEGACY_INSTALL_SUBDIRS = [LEGACY_INSTALL_SUBDIR], identifies installation method to determine upgrade strategy, builds platform binary names in the form sentry-${os}-${arch}${libcSuffix}${suffix}, and uses getsentry/cli as a GitHub repository source.packages/cli/src/lib/binary.ts includes an ldd --version heuristic because musl ldd writes "musl libc" to stderr.packages/cli/src/lib/binary.ts includes UpgradeSourceNotFoundError, parseUpgradeJson, PRIMARY_UPGRADE_SOURCE, and UpgradeSource, plus helpers for constructing the GitHub API URL used to discover a source’s latest CLI release.packages/cli/src/lib/ghcr.ts implements a GHCR/OCI client for downloading nightly CLI binaries from ghcr.io/getsentry/cli; nightly builds are pushed as OCI artifacts via ORAS with the version stored in the manifest annotation.ghcr.io anonymous token exchange rather than user-supplied authentication.annotations.version from the OCI manifest and requires exactly 2 HTTP requests: one token exchange and one manifest fetch.fetch with redirect: "follow" would forward the Authorization header to Azure and produce HTTP 404, so packages/cli/src/lib/ghcr.ts manually follows the redirect without the auth header.packages/cli/src/lib/ghcr.ts imports semver valid as semverValid and imports PRIMARY_UPGRADE_SOURCE, parseUpgradeJson, and UpgradeSource from ./binary.js.packages/cli/src/lib/ghcr.ts defines GhcrManifestHttpError, validates OCI manifest data with isOciManifest, supports retry options including a timeout override and external AbortSignal, preserves external aborts via rethrowExternalAbort(error, signal), and exports listTags.