majkinetor / au

Chocolatey Automatic Package Updater Module
GNU General Public License v2.0
227 stars 71 forks source link

Where I can add headers when downloading file ? #263

Closed Starmania closed 2 years ago

Starmania commented 2 years ago

Hey, I'm curently triing to download a release to calculate his SHA, but the file when downloading, need some headers...

I don't know why but if I do by Invoke-WebRequest in my terminal, all is fine, but if I do by AU, I reach a 403 err...

majkinetor commented 2 years ago

You can use $Latest.Options.Headers

Starmania commented 2 years ago

This is a variable that I set before the update command ?

majkinetor commented 2 years ago

You set it in Get-Latest.