From 517c0c62967397abd6f43bd8e8dfdfd5af9505e3 Mon Sep 17 00:00:00 2001 From: Eden Zimbelman Date: Wed, 6 Aug 2025 23:08:13 -0700 Subject: [PATCH 1/4] fix: hide version checks at the end of windows install script --- scripts/install-windows-dev.ps1 | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/scripts/install-windows-dev.ps1 b/scripts/install-windows-dev.ps1 index 865e8fbb..7eb6a79a 100644 --- a/scripts/install-windows-dev.ps1 +++ b/scripts/install-windows-dev.ps1 @@ -326,11 +326,11 @@ function terms_of_service { [Parameter(HelpMessage = "Alias of Slack CLI")] [string]$Alias ) - $confirmed_alias = check_slack_binary_exist $Alias $Version $false - if (Get-Command $confirmed_alias) { - Write-Host "`nUse of the Slack CLI should comply with the Slack API Terms of Service:" - Write-Host " https://slack.com/terms-of-service/api" - } + # $confirmed_alias = check_slack_binary_exist $Alias $Version $false + # if (Get-Command $confirmed_alias) { + Write-Host "`nUse of the Slack CLI should comply with the Slack API Terms of Service:" + Write-Host " https://slack.com/terms-of-service/api" + # } } function next_step_message { @@ -368,6 +368,6 @@ Write-Host "`nAdding developer tooling for an enhanced experience..." install_git $SkipGit install_deno_vscode_extension $SkipDeno Write-Host "Sweet! You're all set to start developing!" -feedback_message $Alias +# feedback_message $Alias terms_of_service $Alias -next_step_message $Alias +# next_step_message $Alias From f411ccc45209748323ce8858644957c69d63516c Mon Sep 17 00:00:00 2001 From: Eden Zimbelman Date: Fri, 29 Aug 2025 16:05:57 -0700 Subject: [PATCH 2/4] fix: swap fingerprint for version --- scripts/install-windows-dev.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/install-windows-dev.ps1 b/scripts/install-windows-dev.ps1 index 8f093bfe..6c8ab873 100644 --- a/scripts/install-windows-dev.ps1 +++ b/scripts/install-windows-dev.ps1 @@ -58,7 +58,7 @@ function check_slack_binary_exist() { delay 0.2 "Heads up! A binary called ``$SLACK_CLI_NAME`` was found!" delay 0.3 "Now checking if it's the same Slack CLI..." } - & $SLACK_CLI_NAME _fingerprint | Tee-Object -Variable get_finger_print | Out-Null + & $SLACK_CLI_NAME --version | Tee-Object -Variable slack_cli_version | Out-Null if ($get_finger_print -ne $FINGERPRINT) { & $SLACK_CLI_NAME --version | Tee-Object -Variable slack_cli_version | Out-Null if (!($slack_cli_version -contains "Using ${SLACK_CLI_NAME}.exe v")) { @@ -218,7 +218,7 @@ function terms_of_service { [Parameter(HelpMessage = "Alias of Slack CLI")] [string]$Alias ) - # $confirmed_alias = check_slack_binary_exist $Alias $Version $false + $confirmed_alias = check_slack_binary_exist $Alias $Version $false # if (Get-Command $confirmed_alias) { Write-Host "`nUse of the Slack CLI should comply with the Slack API Terms of Service:" Write-Host " https://slack.com/terms-of-service/api" From 18f4fdefa3705436a52759dd5975bcc9534dbe65 Mon Sep 17 00:00:00 2001 From: Eden Zimbelman Date: Fri, 29 Aug 2025 16:17:45 -0700 Subject: [PATCH 3/4] fix: remove existing installation checks --- scripts/install-windows-dev.ps1 | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/scripts/install-windows-dev.ps1 b/scripts/install-windows-dev.ps1 index 6c8ab873..728ae070 100644 --- a/scripts/install-windows-dev.ps1 +++ b/scripts/install-windows-dev.ps1 @@ -58,19 +58,6 @@ function check_slack_binary_exist() { delay 0.2 "Heads up! A binary called ``$SLACK_CLI_NAME`` was found!" delay 0.3 "Now checking if it's the same Slack CLI..." } - & $SLACK_CLI_NAME --version | Tee-Object -Variable slack_cli_version | Out-Null - if ($get_finger_print -ne $FINGERPRINT) { - & $SLACK_CLI_NAME --version | Tee-Object -Variable slack_cli_version | Out-Null - if (!($slack_cli_version -contains "Using ${SLACK_CLI_NAME}.exe v")) { - Write-Host "Error: Your existing ``$SLACK_CLI_NAME`` command is different from this Slack CLI!" - Write-Host "Halting the install to avoid accidentally overwriting it." - - Write-Host "`nTry using an alias when installing to avoid name conflicts:" - Write-Host "`nirm https://downloads.slack-edge.com/slack-cli/install-windows.ps1 -Alias your-preferred-alias | iex" - throw - } - } - $message = "It is the same Slack CLI! Upgrading to the latest version..." if ($Version) { $SLACK_CLI_VERSION = $Version $message = "It is the same Slack CLI! Switching over to v$Version..." From f32fa48f70f711c5b7b9fae6bbc7d91bf795f16b Mon Sep 17 00:00:00 2001 From: Eden Zimbelman Date: Fri, 29 Aug 2025 16:24:08 -0700 Subject: [PATCH 4/4] feat: change the windows exit code --- scripts/install-windows-dev.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/install-windows-dev.ps1 b/scripts/install-windows-dev.ps1 index 728ae070..4fabbfe0 100644 --- a/scripts/install-windows-dev.ps1 +++ b/scripts/install-windows-dev.ps1 @@ -247,7 +247,7 @@ function next_step_message { trap { Write-Host "`nWe would love to know how things are going. Really. All of it." Write-Host "Submit installation issues: https://github.com/slackapi/slack-cli/issues" - exit 1 + exit 7 } install_slack_cli $Alias $Version