Added a way to inspect installation scripts on Powershell(Windows) (#5157)

## Summary
### command
 ```powershell
    powershell -c "irm https://astral.sh/uv/install.ps1 | more"
 ```
Add a method to inspect installation script files that works on Windows,
it may not work on other platforms supported by PowerShell. <br>
Other platforms information:
[PowerShell differences on non-Windows platforms / General Unix
interoperability
changes](https://learn.microsoft.com/en-us/powershell/scripting/whats-new/unix-support?view=powershell-7.4#general-unix-interoperability-changes)
[Differences between Windows PowerShell 5.1 and PowerShell 7.x / Removal
of the more
function](https://learn.microsoft.com/en-us/powershell/scripting/whats-new/differences-from-windows-powershell?view=powershell-7.4#removal-of-the-more-function)
<!-- What's the purpose of the change? What does it do, and why? -->

## Test Plan
**terminal**
* Powershell Version: 5.1.22621.3880 (Windows)

![image](https://github.com/user-attachments/assets/418c10a4-f672-4c79-9d3b-7c58822316dd)
* Powershell Version: 7.4.3 (Windows)

![image](https://github.com/user-attachments/assets/9ee73310-a244-4320-a092-df8c6f0745c5)

## Result (Website)

![image](https://github.com/user-attachments/assets/3faede7d-4004-4e2c-b35a-80147532019b)

---------

Co-authored-by: Zanie Blue <contact@zanie.dev>
This commit is contained in:
FishAlchemist 2024-07-19 22:28:46 +08:00 committed by GitHub
parent 149c612026
commit b1a350cb9f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -21,7 +21,11 @@ uv is installed to `~/.cargo/bin`.
The installation script may be inspected with: The installation script may be inspected with:
```bash ```bash
# On macOS and Linux.
curl -LsSf https://astral.sh/uv/install.sh | less curl -LsSf https://astral.sh/uv/install.sh | less
# On Windows.
powershell -c "irm https://astral.sh/uv/install.ps1 | more"
``` ```
Alternatively, the installer or binaries can be downloaded directly from [GitHub](#github-releases). Alternatively, the installer or binaries can be downloaded directly from [GitHub](#github-releases).