Skip to content

autoupdate 1/3: Add config and detection utilities#1767

Open
yahanxing-stripe wants to merge 1 commit into
v2from
yx/autoupdate-1-config
Open

autoupdate 1/3: Add config and detection utilities#1767
yahanxing-stripe wants to merge 1 commit into
v2from
yx/autoupdate-1-config

Conversation

@yahanxing-stripe

@yahanxing-stripe yahanxing-stripe commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Introduce pkg/autoupdate package with helpers to detect whether the CLI was installed via curl (~/.stripe/bin/) and whether auto-update is opted out
  • Opt-out via STRIPE_NO_AUTO_UPDATE=1 env var or auto_update = false in ~/.config/stripe/config.toml
  • Exposes GetStateDir() for later use by the checker and updater

This is part 1/3 of the auto-update feature for curl-installed binaries.
Stack: this#1768 (checker) → #1769 (apply)

Test plan

  • Unit tests for opt-out detection (env var, config.toml true/false, missing config)
  • Unit test for curl install detection via env override

🤖 Generated with Claude Code

Introduce pkg/autoupdate with helpers to detect whether the CLI was
installed via curl (~/.stripe/bin/) and whether auto-update is opted
out (via STRIPE_NO_AUTO_UPDATE env or config.toml setting).

This is part 1/3 of the auto-update feature for curl-installed binaries.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Committed-By-Agent: claude
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.

3 participants