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

Get-ChocolateyWebFile download check enhancements #952

Closed
3 tasks done
ferventcoder opened this issue Sep 8, 2016 · 0 comments
Closed
3 tasks done

Get-ChocolateyWebFile download check enhancements #952

ferventcoder opened this issue Sep 8, 2016 · 0 comments

Comments

@ferventcoder
Copy link
Member

ferventcoder commented Sep 8, 2016

Sometimes the file size is about the same as a previous install. If you are running only Get-ChocolateyWebFile and attempting to download a file to the same location every time, it's possible that the file won't get downloaded because the check determines it doesn't need to download a file.

  • Add -ForceDownload to force the re-download of a file when there may be an existing file.
  • Validate an existing file against supplied checksum and download if the current file fails the checksum.
  • Don't do the check against length if there is a checksum present.

Reference: https://groups.google.com/d/msgid/chocolatey/ff442f6c-c7a9-4a42-bc22-872016af4e23%40googlegroups.com

@ferventcoder ferventcoder added this to the 0.10.2 milestone Sep 8, 2016
@ferventcoder ferventcoder changed the title Get-ChocolateyWebFile should have a method to force the updated download Get-ChocolateyWebFile download check enhancements Sep 8, 2016
@ferventcoder ferventcoder modified the milestones: 0.10.1, 0.10.2 Sep 10, 2016
@ferventcoder ferventcoder self-assigned this Sep 10, 2016
ferventcoder added a commit that referenced this issue Sep 12, 2016
- If there is a checksum, use that to verify an exising file instead of
`Content-Length` from web headers as sometimes different versions of a
file will have the same size and could result in false positives.
- Only verify file size and remote checksum if an original checksum is
not available with the package.
- Add `-ForceDownload` to ensure a file is always redownloaded
ferventcoder added a commit that referenced this issue Sep 12, 2016
* stable: (24 commits)
  (GH-839) Switch to apply package parameters to dependent packages
  (maint) formatting methods / parameters in calls
  (GH-958) If SSLv3 in Posh v2 Fails, Use Original
  (GH-746) Use HTTPS if available when HTTP url
  (GH-957) Skip Get-WebFileName When FTP
  (GH-948) Ensure passwords / keys are not logged
  (GH-952) Get-ChocolateyWebFile enhancements
  (doc) update generated docs
  (maint) formatting
  (docs) move GenerateDocs.ps1 / update
  (GH-932) Do not set unknown checksum to 'md5'
  (GH-719) Reset ServerCertificateValidationCallback
  (GH-305) add MSP/MSU installer types
  (GH-305) update exitcodes to long
  (GH-954) Pending fails when lib does not exist
  (GH-950) Install-ChocolateyPackage - UseOriginalLocation
  (maint) formatting
  (GH-922) Automatically determine checksum type
  (maint) fixes for shimgen
  (GH-948) Do not log sensitive arguments
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants