Skip to content
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

Powershell install script returns 404 #1123

Closed
luxus opened this issue Apr 1, 2021 · 4 comments
Closed

Powershell install script returns 404 #1123

luxus opened this issue Apr 1, 2021 · 4 comments
Labels
bug Something isn't working

Comments

@luxus
Copy link

luxus commented Apr 1, 2021

Describe the bug

PowerShell 7.2.0-preview.4
Copyright (c) Microsoft Corporation.

https://aka.ms/powershell
Type 'help' to get help.

PS C:\Users\luxus> (iwr https://git.io/chezmoi.ps1).Content | powershell -c -
checking GitHub for tag latest
found tag v2.0.7 for latest
found version 2.0.7 for latest/windows/amd64
An error occurred while installing: Exception calling "DownloadFile" with "2" argument(s): "The remote server returned an error: (404) Not Found."
PS C:\Users\luxus>

To reproduce

Open a windows terminal
enter the (iwr https://git.io/chezmoi.ps1).Content | powershell -c -

Expected behavior

Installation of Chezmoi

Additional context

windows build 21343.1000
PowerShell 7.2.0-preview.4

@twpayne twpayne added the investigating This is a bit weird, not sure if this is a bug yet label Apr 1, 2021
@twpayne
Copy link
Owner

twpayne commented Apr 1, 2021

It looks like iwr is not following the redirect from https://git.io/chezmoi.ps1 to https://raw.githubusercontent.com/twpayne/chezmoi/master/assets/scripts/install.ps1.

I had a quick look at the iwr documentation but didn't see any mention of redirects.

@zb140 you know this area the best, do you know what could be happening here?

@zb140
Copy link
Collaborator

zb140 commented Apr 1, 2021

Actually, I'm pretty sure it's just because the checksums file got renamed and the script is still looking for the old name. We know it's not the initial redirect because the first 3 lines of output are actually from install.ps1 so it must be executing.

I can fix it in a few hours after work, but I'm pretty sure just changing this to checksums.txt will do the trick. I noticed the change in the bash install script the other day but for whatever reason it didn't click that the Powershell one would probably need updating too. Sorry about that!

@zb140
Copy link
Collaborator

zb140 commented Apr 1, 2021

@persalmi fixed this for us in #1125. Thanks, all!

@zb140 zb140 closed this as completed Apr 1, 2021
@persalmi
Copy link
Contributor

persalmi commented Apr 2, 2021

Missed that there was a registered issue for it...

@twpayne twpayne added bug Something isn't working and removed investigating This is a bit weird, not sure if this is a bug yet labels Apr 4, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants