Repository navigation
feat(cli): Add a PowerShell installer for Windows #1511
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
6d76b75
feat(cli): Add a PowerShell installer for Windows
sentry-junior[bot] 2e70ada
fix(cli): Fail the PowerShell installer when sentry init fails
sentry-junior[bot] 37ac1b4
ref(cli): Resolve installer downloads from the release registry
sentry-junior[bot] 9c94663
ci(cli): Smoke test the PowerShell installer on Windows
sentry-junior[bot] be34f0d
ci(cli): Smoke test the bash installer and drop legacy release coverage
sentry-junior[bot] File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,76 @@ | ||
| name: Install Scripts | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| on: | ||
| push: | ||
| branches: [main] | ||
| paths: | ||
| - ".github/workflows/install-scripts.yml" | ||
| - "packages/cli/install" | ||
| - "packages/cli/install.ps1" | ||
| pull_request: | ||
| paths: | ||
| - ".github/workflows/install-scripts.yml" | ||
| - "packages/cli/install" | ||
| - "packages/cli/install.ps1" | ||
|
|
||
| jobs: | ||
| unix-bash: | ||
| name: bash installs latest (${{ matrix.os }}) | ||
| runs-on: ${{ matrix.os }} | ||
| timeout-minutes: 15 | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| os: [ubuntu-latest, macos-latest] | ||
| env: | ||
| SENTRY_CLI_NO_TELEMETRY: "1" | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Install through curl | bash | ||
| run: | | ||
| export SENTRY_INSTALL_DIR="$RUNNER_TEMP/sentry-bin" | ||
| bash < packages/cli/install | ||
| installed=$("$SENTRY_INSTALL_DIR/sentry" --version) | ||
| echo "Installed sentry $installed" | ||
|
|
||
| - name: Find sentry on PATH in a later step | ||
| run: | | ||
| echo "Resolved $(command -v sentry)" | ||
| sentry --version | ||
|
|
||
| windows-powershell: | ||
| name: ${{ matrix.shell }} installs latest | ||
| runs-on: windows-latest | ||
| timeout-minutes: 15 | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| # pwsh is PowerShell 7; powershell is the Windows PowerShell 5.1 that | ||
| # ships with Windows. | ||
| shell: [pwsh, powershell] | ||
| defaults: | ||
| run: | ||
| shell: ${{ matrix.shell }} | ||
| env: | ||
| SENTRY_CLI_NO_TELEMETRY: "1" | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Install through Invoke-Expression | ||
| run: | | ||
| $env:SENTRY_INSTALL_DIR = Join-Path $env:RUNNER_TEMP 'sentry-bin' | ||
| Get-Content -Raw -LiteralPath packages/cli/install.ps1 | Invoke-Expression | ||
| $installed = & (Join-Path $env:SENTRY_INSTALL_DIR 'sentry.exe') --version | ||
| if ($LASTEXITCODE -ne 0) { throw "sentry --version exited with $LASTEXITCODE" } | ||
| "Installed sentry $installed" | ||
|
|
||
| - name: Find sentry on PATH in a later step | ||
| run: | | ||
| $command = Get-Command sentry -ErrorAction Stop | ||
| "Resolved $($command.Source)" | ||
| sentry --version | ||
| if ($LASTEXITCODE -ne 0) { throw "sentry --version exited with $LASTEXITCODE" } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../../../packages/cli/install.ps1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.