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

(#3191) Pass options to Get-WebHeaders #3395

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

flcdrg
Copy link
Member

@flcdrg flcdrg commented Feb 12, 2024

Description Of Changes

Pass $options through to Get-WebFileName and Get-WebHeaders

  • For remaining headers that don't require special support, check that they aren't 'restricted' before adding them to the Headers collection.

Motivation and Context

Allows being able to set headers via functions like Install-ChocolateyPackage and ensure that those headers are used appropriately.

Testing

Operating Systems Testing

Change Types Made

  • Bug fix (non-breaking change).
  • Feature / Enhancement (non-breaking change).
  • Breaking change (fix or feature that could cause existing functionality to change).
  • Documentation changes.
  • PowerShell code changes.

Change Checklist

  • Requires a change to the documentation.
  • Documentation has been updated.
  • Tests to cover my changes, have been added.
  • All new and existing tests passed?
  • PowerShell code changes: PowerShell v2 compatibility checked?

Related Issue

Fixes #3191

@flcdrg flcdrg marked this pull request as ready for review June 10, 2024 08:53
@flcdrg
Copy link
Member Author

flcdrg commented Sep 18, 2024

This may also possibly resolve chocolatey/chocolatey-licensed-issues#372

@pfremy
Copy link

pfremy commented Dec 16, 2024

I have use for that change too

Or any way to provide implicitely user credentials for some url, in the same principle as is done with "source"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Get-ChocolateyWebFile should pass the Options parameter to Get-WebFileName and Get-WebHeaders
2 participants