summaryrefslogtreecommitdiff
path: root/lib/chef/provider/package/windows.rb
Commit message (Collapse)AuthorAgeFilesLines
* Bugfix: checksum validation (#13210)Joseph Larionov2022-11-011-1/+1
| | | | | | | | | | * Add a case-insensitive helper to determine if two checksums match * Use case-insensitive checksum match helper for checksum validation This fixes a bug where checksum validation fails because the two checksums are in different letter cases. The existing checksum validation logic was using case sensitive equality checks. Signed-off-by: Joseph Larionov <jlarionov@webmd.net>
* Resolve our chefstyle warningsredundant_beginsTim Smith2021-04-011-4/+2
| | | | | | Now that knife has been moved we can resolve the current warnings Signed-off-by: Tim Smith <tsmith@chef.io>
* use autoloading for many required gemsmwrock2020-09-081-2/+2
| | | | Signed-off-by: mwrock <matt@mattwrock.com>
* fix windows package for Chef-16 regressionLamont Granquist2020-07-201-4/+9
| | | | | | | I didn't realize that the source_package was being used to collect the merged state off of the property. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Downcase checksums when they come into the system.Pete Higgins2020-05-191-1/+1
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Get lib/ free of spelling violations.Pete Higgins2020-05-181-1/+1
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* remove other source_resource referenceLamont Granquist2020-05-041-1/+1
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Fix windows package super bug and cleanupLamont Granquist2020-05-041-51/+26
| | | | | | | | | | | Remove the overriding of the action block entirely and clean up some overly complicated code. In the process it looks like the "unknown" version codepath is blatantly entirely unused, so it was removed. A bunch of extra unnecessary indirection was also removed. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Remove copyright dateslcg/remove-copyright-datesLamont Granquist2020-04-131-1/+1
| | | | | | | | Legally incredibly dubious, particularly since we don't follow it strictly as policy, and we have git history instead, which does it right. This is just a waste of time and a cargo cult. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Use the action DSL consistentlyLamont Granquist2020-03-021-1/+1
| | | | | | | | May be a potentially breaking change if I noodle hard enough on it, it does mean that all the actions are now (correctly) encapsulated in a sub-resource collection, whereas before they never had one. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* add require for CGIlcg/unescapeLamont Granquist2020-02-201-1/+2
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* fix ruby 2.7 URI.unescape deprecationLamont Granquist2020-02-201-1/+1
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* fix a bunch of weirdly mangled require linesLamont Granquist2019-05-081-1/+1
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Convert require to require_relativeLamont Granquist2019-05-081-7/+7
| | | | | | | This gives a speed boost since rubygems does not have to scan through every gem in the gemset in order to find the file. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* more parenthesized yappinglcg/document-buggy-windows-package-thingsLamont Granquist2018-09-281-1/+7
| | | | | | confusing use case is very confusing. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* add some big FIXMEsLamont Granquist2018-09-281-1/+17
| | | | | | | | | the windows package provider is doing some very strange, and very likely very buggy things. i don't have the time or the knowledge right now to unwind these though. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Merge pull request #7353 from MsysTechnologiesllc/dh/package_options_sensitiveTim Smith2018-08-131-0/+1
|\ | | | | windows_package: Fix package sensitive error
| * update to pass sensitive as optiondheerajd-msys2018-06-131-0/+1
| | | | | | | | Signed-off-by: dheerajd-msys <dheeraj.dubey@msystechnologies.com>
* | package: Make sure to use the package_name name propertiesname_propertiesTim Smith2018-06-121-3/+3
| | | | | | | | | | | | I noticed we weren't using the package_name name property in most of our why-run or logging messages in various package providers. This would lead to some pretty confusing log output when using the name property. Signed-off-by: Tim Smith <tsmith@chef.io>
* | Add whyrun message when installing a local from on windowsJosh Barker2018-06-091-0/+1
|/ | | | Signed-off-by: Josh Barker <josh.barker.developer@gmail.com>
* Check local file exists before installing a windows packageJosh Barker2018-05-261-0/+7
| | | | Signed-off-by: Josh Barker <josh.barker.developer@gmail.com>
* mechanical conversion of most debug log statements to traceThom May2018-03-261-5/+5
| | | | Signed-off-by: Thom May <thom@chef.io>
* Remove a few more provides and update the resolver specTim Smith2018-03-071-1/+1
| | | | | | We need to rethink this spec. The 1:1 mapping stuff doesn't seem like it has a lot of value. The portion below where we test 1:many mappings seem to be the value. I want to know the right thing mapped to package, service, or user on Debian XYZ. Signed-off-by: Tim Smith <tsmith@chef.io>
* Add version_equals? method to windows providerJon Cowie2017-09-221-0/+4
| | | | Signed-off-by: Jon Cowie <jcowie@chef.io>
* Cater for Windows package managers using the version string "latest"Jon Cowie2017-09-221-0/+11
| | | | | | Some windows package managers use the version string "latest" - when this happens, have version_compare always return 0, as we can't reliably tell what version number we're looking at. Signed-off-by: Jon Cowie <jcowie@chef.io>
* package provider cleanuplcg/package-cleanupLamont Granquist2017-02-111-3/+3
| | | | | | | | | - cleans up a lot of ivar usage - converts most providers to shell_out_compact_timeout! - almost deprecates a few APIs, but can't quite yet - windows providers need mixlib-shellout to take an argv Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Style/NumericPredicate comparison stylelcg/numericpredicateLamont Granquist2016-12-211-1/+1
| | | | | | | | | | | | | Apparently rubocop thinks the default behavior should be that we have to rewrite every use of `foo == 0` into `foo.zero?` which is a big pile of NOPE for me. After discovering that `.zero?` is actually slower, I'd prefer to go the other direction. Same for `positive?` and `negative?`. These are the only uses of `zero?` in the chef/chef codebase, while I'm pretty sure the inverse rule would touch nearly every file. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Fixed undefined short_cksum method issue and checksum in uppercase issue for ↵Aliasgar162016-09-201-1/+1
| | | | | | | | | | windows_package resource. (#5332) * Fixed undefined short_cksum method issue and checksum in uppercase issue for windows_package resource. * Added RSpecs for the changes done here. * Fixed RSpecs issues.
* Forward package cookbook_name to underlying remote_fileBaptiste Courtois2016-07-221-0/+2
|
* update to latest chefstyle - fix casecmptm/fix_casecmpThom May2016-04-201-1/+1
|
* fixes #4639 and returns true from define_resource_requirements for MSIsmsiMatt Wrock2016-02-291-1/+1
|
* fixed exe package downloadsMatt Wrock2016-02-221-30/+39
|
* auto fixing some rubocopsLamont Granquist2016-02-091-1/+1
| | | | | | | | | Style/NegatedWhile Style/ParenthesesAroundCondition Style/WhileUntilDo Style/WordArray Performance/ReverseEach Style/ColonMethodCall
* autofixing whitespace copsLamont Granquist2016-02-051-2/+2
| | | | | | | | | | | | | | | | | | | | | | 4174 Style/SpaceInsideHashLiteralBraces 1860 Style/SpaceAroundOperators 1336 Style/SpaceInsideBlockBraces 1292 Style/AlignHash 997 Style/SpaceAfterComma 860 Style/SpaceAroundEqualsInParameterDefault 310 Style/EmptyLines 294 Style/IndentationConsistency 267 Style/TrailingWhitespace 238 Style/ExtraSpacing 212 Style/SpaceBeforeBlockBraces 166 Style/MultilineOperationIndentation 144 Style/TrailingBlankLines 120 Style/EmptyLineBetweenDefs 101 Style/IndentationWidth 82 Style/SpaceAroundBlockParameters 40 Style/EmptyLinesAroundMethodBody 29 Style/EmptyLinesAroundAccessModifier 1 Style/RescueEnsureAlignment
* Copyright year update for 2016 and massive cleanup.Noah Kantrowitz2016-02-021-1/+1
| | | Generated via git ls-files | xargs perl -pi -e "s/[Cc]opyright (?:\([Cc]\) )?((?\!$(date +%Y))\\d{4})(-\\d{4})?([, ][ \d]+)*(,|(?= ))/Copyright \\1-$(date +%Y),/g"
* Use double quotes by defaultThom May2016-01-141-11/+11
| | | | | | | This is an entirely mechanically generated (chefstyle -a) change, to go along with chef/chefstyle#5 . We should pick something and use it consistently, and my opinion is that double quotes are the appropriate thing.
* Correct uses of fail to raisetm/fix_failThom May2016-01-131-1/+1
| | | | Style/SignalException - 3
* fix some lint copsLamont Granquist2016-01-121-1/+1
| | | | | | | | | fixes the following offenses: 46 Lint/EndAlignment 21 Lint/BlockAlignment 3 Lint/SpaceBeforeFirstArg 1 Lint/DefEndAlignment
* fixing post merge test breaksMatt Wrock2015-12-151-1/+1
|
* non msi packages must explicitly provide a source attribute on installMatt Wrock2015-12-151-12/+21
|
* Use properties in package resourcesjk/package-propertiesJohn Keiser2015-12-151-2/+2
|
* adds support to installer types inno, nsis, wise and installshield top the ↵Matt Wrock2015-12-071-14/+95
| | | | windows_package resource
* download_file_missing? -> downloadable_file_missing?Jay Mundrawala2015-05-151-2/+2
|
* Surface checksum attributeJay Mundrawala2015-05-151-0/+16
|
* Allow users to override remote_file attributes in windows_packageJay Mundrawala2015-05-151-10/+18
|
* Refactor uri detectionJay Mundrawala2015-05-151-17/+7
|
* Modify windows package provider to allow urlJay Mundrawala2015-05-151-6/+76
|
* Make sure windows_service and windows_package resources are found with the ↵Serdar Sutay2014-10-281-2/+5
| | | | new dynamic provider resolver.
* CHEF-5322: Add utility for validating Windows pathsBryan McLellan2014-06-051-0/+3
|
* CHEF-5087: Add a Windows Installer package providerBryan McLellan2014-03-271-0/+80
Adds the framework for a windows package provider, which must determine the correct provider by examining metadata about the source file, or the source file itself. Provides FFI based access to the Windows Installer functions to retrieve metadata from the MSI files and from the Windows product database. Combines both of these into an MSI package provider. Continues to work alongside the windows_package LWRP.