Update repository references and migration instructions#297
Update repository references and migration instructions#297akalipetis wants to merge 5 commits intomainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates repository references from platformsh/cli to upsun/cli across configuration files, installer script, and README, and adds migration warnings to guide users to the new repository.
Changes:
- Updated GitHub repository and Homebrew tap references in configuration files (
upsun-cli.yaml,platformsh-cli.yaml) - Modified installer script to use new repository URLs and added interactive migration warning with user prompt
- Updated README with prominent migration notice and installer URL references
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| internal/config/upsun-cli.yaml | Updated homebrew_tap and github_repo to reference upsun organization |
| internal/config/platformsh-cli.yaml | Updated homebrew_tap and github_repo to reference upsun organization |
| installer.sh | Updated download URLs to upsun/cli; added migration warning system with interactive prompt, skip flag, and helper functions |
| README.md | Added migration notice at top; updated all installer URLs and download links to reference new repository |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| fi | ||
|
|
||
| # Read from /dev/tty to get input even when script is piped | ||
| read -r -p " Do you want to continue with this installer? [y/N] " response < /dev/tty |
There was a problem hiding this comment.
@miguelsanchez-upsun I didn't get this prompt when calling this script with
curl https://raw.githubusercontent.com/platformsh/cli/e5b2eb06e3826d97ba318500084a1345ac6851ab/installer.sh | bashin iTerm2 on macOS
it just continues with the installation
but also... do we need to redirect the user in this case? when we could instead modify the script to install the new package (but preserving the same vendor behavior as before)
There was a problem hiding this comment.
Fixed in ff1dcd5. is_interactive was using [ -t 0 ], which is false when piped from curl. Now checks /dev/tty directly (with a real open attempt so it also doesn't break in no-TTY environments like CI).
Testing commands:
# TTY prompts
docker run --rm -it -v "$PWD":/w -w /w debian:bookworm-slim bash -c 'cat installer.sh | bash'
# Non TTY should not prompt
docker run --rm -v "$PWD":/w -w /w debian:bookworm-slim bash -c 'cat installer.sh | bash'
There was a problem hiding this comment.
On your second point. Seems to me that, we are going to try to install the new package, but only on RAW installs:
docker run --rm -v "$PWD":/w -w /w debian:bookworm bash -c 'apt-get update && apt-get install -y curl && cat installer.sh | INSTALL_METHOD=raw bash && platform version'
... installation process ...
Downloading https://github.com/upsun/cli/releases/download/v5.10.1/platform_v5.10.1_linux_arm64.tar.gz
curl: (22) The requested URL returned error: 404
the download failed
That fails because we changed the versioning format of the packages platform_5.10.1 not platform_v5.10.1
On the other hand, regular installs will go and download from cloudsmith.
docker run --rm -v "$PWD":/w -w /w debian:bookworm bash -c 'apt-get update && apt-get install -y curl && cat installer.sh | bash && platform version'
... installation process ...
| Get:1 https://dl.cloudsmith.io/public/platformsh/cli/deb/debian bookworm/main arm64 platformsh-cli arm64 5.9.0 [16.2 MB]
... installation process ...
Thank you for using Upsun (formerly Platform.sh)!
Upsun CLI (Platform.sh compatibility) 5.9.0
Is a matter of whether we want to force install the new version and users should have a platform binary at the end of the installation. Or we want to keep this installer as a backwards compatibility and let users move to the new one. At the moment i think we are mixing both and it can be confusing at best.
There was a problem hiding this comment.
Installing the new version sounds correct, but we'll want the binary name and config to stay platform unless VENDOR is set to upsun
| output_stderr "" | ||
| output_stderr "\033[33m+-------------------------------------------------------------------------------------+\033[0m" | ||
| output_stderr "\033[33m| |\033[0m" | ||
| output_stderr "\033[33m| WARNING: This repository (platformsh/cli) has been migrated to upsun/cli |\033[0m" |
There was a problem hiding this comment.
There was a problem hiding this comment.
Renamed it to NOTICE on 7f43487.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Update migration instructions to inform users about the repository change to
upsun/cli. Update Homebrew tap and GitHub repository references in configuration files and scripts to reflect the new repository. Add a warning in the installer script to guide users towards the new installation method.