Skip to content

feat(install): add SENTRY_INIT env var to run wizard after install#685

Merged
BYK merged 1 commit intomainfrom
feat/ephemeral-init-script
Apr 9, 2026
Merged

feat(install): add SENTRY_INIT env var to run wizard after install#685
BYK merged 1 commit intomainfrom
feat/ephemeral-init-script

Conversation

@betegon
Copy link
Copy Markdown
Member

@betegon betegon commented Apr 7, 2026

Summary

Lets users install the CLI and launch the setup wizard in one command:

curl -fsSL https://cli.sentry.dev/install | SENTRY_INIT=1 bash

After the normal install completes, resolves the installed binary by checking the same candidate directories as the TS code (SENTRY_INSTALL_DIR > ~/.local/bin > ~/bin > ~/.sentry/bin), then runs sentry init </dev/tty. The </dev/tty reopens stdin from the terminal since curl | bash consumes it for the pipe.

Also adds install to the docs-preview workflow path filter — changes to the install script weren't triggering preview builds because the symlink in docs/public/ doesn't match the docs/** glob.

Test plan

  • curl -fsSL .../install | SENTRY_INIT=1 bash — installs CLI, then launches wizard with working interactive prompts
  • curl -fsSL .../install | bash (without env var) — normal install, no wizard
  • Verify binary is found even when installed to ~/.sentry/bin (fallback path)

Closes #682

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

Semver Impact of This PR

🟡 Minor (new features)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


New Features ✨

  • (commands) Add buildRouteMap wrapper with standard subcommand aliases by BYK in #690
  • (config) Support .sentryclirc config file for per-directory defaults by BYK in #693
  • (install) Add SENTRY_INIT env var to run wizard after install by betegon in #685

Bug Fixes 🐛

Dashboard

  • Add --layout flag to widget add for predictable placement by BYK in #700
  • Render tracemetrics widgets in dashboard view by BYK in #695

Other

  • (build) Enable sourcemap resolution for compiled binaries by BYK in #701
  • (init) Narrow command validation to actual shell injection vectors by betegon in #697
  • (init,feedback) Default to tracing only in feature select and attach user email to feedback by MathurAditya724 in #688
  • (setup) Handle read-only .claude directory in sandboxed environments by BYK in #702

Internal Changes 🔧

  • (docs) Gitignore generated command docs, extract fragments by BYK in #696
  • (eval) Replace OpenAI with Anthropic SDK in init-eval judge by betegon in #683
  • (init) Use markdown pipeline for spinner messages by betegon in #686
  • Regenerate skill files and command docs by github-actions[bot] in 584ec0e0

🤖 This preview updates automatically when you update the PR.

@betegon betegon changed the title feat: add ephemeral init bootstrapper script feat(install): add --init flag for ephemeral wizard runs Apr 7, 2026
@betegon betegon force-pushed the feat/ephemeral-init-script branch from 5245bcd to 67e56c8 Compare April 7, 2026 19:06
@betegon betegon marked this pull request as ready for review April 7, 2026 19:08
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://cli.sentry.dev/pr-preview/pr-685/

Built to branch gh-pages at 2026-04-09 13:46 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

@betegon betegon force-pushed the feat/ephemeral-init-script branch from 6b6df40 to 8b97caa Compare April 7, 2026 19:53
@betegon betegon changed the title feat(install): add --init flag for ephemeral wizard runs feat(install): add SENTRY_INIT env var to run wizard after install Apr 7, 2026
@betegon betegon force-pushed the feat/ephemeral-init-script branch from 8b97caa to 85afd5f Compare April 8, 2026 12:05
@betegon betegon changed the title feat(install): add SENTRY_INIT env var to run wizard after install feat(install): add --init flag to run wizard after install Apr 8, 2026
@betegon betegon force-pushed the feat/ephemeral-init-script branch from 85afd5f to 19f5d97 Compare April 8, 2026 12:18
@betegon betegon changed the title feat(install): add --init flag to run wizard after install feat(install): add SENTRY_INIT env var to run wizard after install Apr 8, 2026
@betegon betegon force-pushed the feat/ephemeral-init-script branch 2 times, most recently from f6b769c to 086c091 Compare April 8, 2026 14:15
@betegon betegon force-pushed the feat/ephemeral-init-script branch 2 times, most recently from 98608e3 to bcdb083 Compare April 8, 2026 19:01
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

Codecov Results 📊

134 passed | Total: 134 | Pass Rate: 100% | Execution Time: 0ms

📊 Comparison with Base Branch

Metric Change
Total Tests
Passed Tests
Failed Tests
Skipped Tests

✨ No test changes detected

All tests are passing successfully.

✅ Patch coverage is 100.00%. Project has 1476 uncovered lines.
✅ Project coverage is 95.46%. Comparing base (base) to head (head).

Coverage diff
@@            Coverage Diff             @@
##          main       #PR       +/-##
==========================================
+ Coverage    95.43%    95.46%    +0.03%
==========================================
  Files          223       223         —
  Lines        32511     32520        +9
  Branches         0         0         —
==========================================
+ Hits         31027     31044       +17
- Misses        1484      1476        -8
- Partials         0         0         —

Generated by Codecov Action

@BYK BYK force-pushed the feat/ephemeral-init-script branch from bcdb083 to 0aef5ad Compare April 9, 2026 13:39
    curl -fsSL https://cli.sentry.dev/install | SENTRY_INIT=1 bash

The binary now reopens /dev/tty itself when stdin is not a TTY, so
clack prompts receive keypress events even when launched from a pipe.
Falls back gracefully in CI/containers where /dev/tty is unavailable.

Closes #682

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@BYK BYK force-pushed the feat/ephemeral-init-script branch from 0aef5ad to 82b85ce Compare April 9, 2026 13:45
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 82b85ce. Configure here.

@BYK BYK merged commit d1e555d into main Apr 9, 2026
26 checks passed
@BYK BYK deleted the feat/ephemeral-init-script branch April 9, 2026 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Offer sentry init as an ephemeral one-liner for users without the CLI installed

2 participants