summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* add a simple smoke testlcg/extract-mixlib-shelloutLamont Granquist2020-07-161-1/+2
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* extracting shell_out helper to mixlib-shelloutLamont Granquist2020-07-151-0/+208
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Bump version to 3.0.11 by Chef Expeditorv3.0.11Chef Expeditor2020-05-211-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Fix a typo.Pete Higgins2020-05-201-1/+1
| | | | Signed-off-by: Pete Higgins <pete@peterhiggins.org>
* Bump version to 3.0.10 by Chef Expeditorv3.0.10Chef Expeditor2020-03-081-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Bump version to 3.0.9 by Chef Expeditorv3.0.9Chef Expeditor2019-12-301-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Substitute require for require_relativeTim Smith2019-12-292-4/+4
| | | | | | require_relative is significantly faster and should be used when available. Signed-off-by: Tim Smith <tsmith@chef.io>
* Bump version to 3.0.8 by Chef Expeditorv3.0.8Chef Expeditor2019-12-301-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Bump version to 3.0.7 by Chef Expeditor3.0.7Chef Expeditor2019-07-301-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Fix return type of Process.create to be a ProcessInfo instance again.Ryan Davis2019-07-302-1/+5
| | | | | | | | | | | | This fixes compatibility with win32-process' Process.create while maintaining the rest of our changes. This moves Process.create to Process.create3. Process.create now calls create3 and returns the ProcessInfo. The break came from PR #177, which is fairly extensive, so I'm only rolling out the return type change on this method. Signed-off-by: Ryan Davis <zenspider@chef.io>
* Bump version to 3.0.6 by Chef Expeditor3.0.6Chef Expeditor2019-07-301-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Blinding applying chefstyle -a.Ryan Davis2019-07-304-12/+31
| | | | Signed-off-by: Ryan Davis <zenspider@chef.io>
* Bump version to 3.0.5 by Chef Expeditor3.0.5Chef Expeditor2019-06-071-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Bump version to 3.0.4 by Chef Expeditorv3.0.4Chef Expeditor2019-06-061-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Merge pull request #177 from visioncritical/load_user_profileLamont Granquist2019-06-062-67/+185
|\ | | | | Load and unload user profile as required
| * cleanup Rubocop violationsBrian Warsing2019-01-261-17/+16
| | | | | | | | Signed-off-by: Brian Warsing <brian.warsing@visioncritical.com>
| * Load and unload user profile as requiredBrian Warsing2019-01-232-67/+186
| | | | | | | | | | | | | | | | | | - bind related C++ funcs, add types and constants - refactor similar func calls into component methods - make Process#create return trio of process-related objects - ensure delayed profile unload and token destruction Signed-off-by: Brian Warsing <brian.warsing@visioncritical.com>
* | Bump version to 3.0.3 by Chef Expeditorv3.0.3Chef Expeditor2019-06-061-1/+1
| | | | | | | | Obvious fix; these changes are the result of automation not creative thinking.
* | Merge pull request #182 from chef/lcg/win-array-argsLamont Granquist2019-06-061-2/+42
|\ \ | | | | | | Support array args on windows WIP
| * | Support array args on windowslcg/win-array-argsLamont Granquist2019-06-061-2/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implements correct quoting and escaping of arguments on windows. That means that this works right now: ```ruby filename = "c:\program files" shell_out("dir", filename); ``` So all the defensive coding around quotes-around-filepaths -- which were all actually buggy even when they worked (trailing backslashes would fail) -- are unnecessary and arguments can just be passed in as an array and this code will sort it out. We rely on the existing determination of if metacharacters mean it needs to run under cmd and if it needs the ^ quoting which seems to be well tested, and which all runs after this does. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* | | Bump version to 3.0.2 by Chef Expeditorv3.0.2Chef Expeditor2019-06-011-1/+1
|/ / | | | | | | Obvious fix; these changes are the result of automation not creative thinking.
* | Fix chefstyle warningsTim Smith2019-04-191-2/+2
| | | | | | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* | Bump version to 3.0.1 by Chef Expeditorv3.0.1Chef Expeditor2019-04-191-1/+1
|/ | | | Obvious fix; these changes are the result of automation not creative thinking.
* update travis/appveyor, drop ruby 2.2 support, test on 2.6lcg/version-bump2Lamont Granquist2019-01-041-1/+1
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Bump version to 2.4.4 by Chef Expeditorv2.4.4Chef Expeditor2018-12-121-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Bump version to 2.4.3 by Chef Expeditorv2.4.3Chef Expeditor2018-12-071-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Bump version to 2.4.2 by Chef Expeditorv2.4.2Chef Expeditor2018-12-061-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Bump version to 2.4.1 by Chef Expeditorv2.4.1Chef Expeditor2018-12-061-1/+1
| | | | Obvious fix; these changes are the result of automation not creative thinking.
* Update the github links in commentsTim Smith2018-10-231-1/+1
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Fix EmptyWindowsCommand error on Windows when the command starts with spacesEric VERNIER2018-07-301-4/+3
| | | | Signed-off-by: Eric Vernier <zerikv@gmail.com>
* Merge pull request #164 from chef/new_rubyv2.4.0Tim Smith2018-07-231-1/+1
|\ | | | | Release 2.4.0
| * Release 2.4.0new_rubyTim Smith2018-07-231-1/+1
| | | | | | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* | Merge pull request #158 from MsysTechnologiesllc/dh/MSYS-847_fix_bare_rescuesTim Smith2018-07-231-2/+2
|\ \ | |/ |/| Fix a bare rescue on Windows
| * [MSYS-847] fix bare rescuedheerajd-msys2018-07-031-2/+2
| | | | | | | | Signed-off-by: dheerajd-msys <dheeraj.dubey@msystechnologies.com>
* | master of chefstyle + fixesLamont Granquist2018-07-061-1/+1
|/ | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* remove hashrocket syntaxlcg/remove-hashrocketsLamont Granquist2018-06-252-9/+9
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* add sensitive featuredheerajd-msys2018-06-153-8/+15
| | | | Signed-off-by: dheerajd-msys <dheeraj.dubey@msystechnologies.com>
* [MSYS-629] Added username,password validation for elavated option (#151)Nimisha Sharad2017-08-091-0/+8
| | | | | | * Added username,password validation for elavated option Signed-off-by: nimisha <nimisha.sharad@clogeny.com>
* Release 2.3.2v2.3.2Bryan McLellan2017-07-211-1/+1
| | | | Signed-off-by: Bryan McLellan <btm@loftninjas.org>
* Fix broken method callBryan McLellan2017-07-211-1/+1
| | | | | | Missed one argument to this method call Signed-off-by: Bryan McLellan <btm@loftninjas.org>
* Release 2.3.1v2.3.1Bryan McLellan2017-07-191-1/+1
| | | | Signed-off-by: Bryan McLellan <btm@chef.io>
* Make Mixlib::ShellOut::EmptyWindowsCommand inherit from ShellCommandFailedBryan McLellan2017-07-191-1/+1
| | | | | | | | | Chef rescues Mixlib::ShellOut::ShellCommandFailed, SystemCallError in a few places. Recent refactors caused EmptyWindowsCommand to be correctly raised where we still unintentionally raised SystemCallError due to a bad FFI call. This gets us closer to not needing to cover these edge cases in rescue clauses everywhere. Signed-off-by: Bryan McLellan <btm@chef.io>
* Release 2.3.0v2.3.0Bryan McLellan2017-07-191-1/+1
|
* Update error messages to indicate user who lacks privilege on WindowsBryan McLellan2017-07-191-140/+118
| | | | | | | In some cases the user running mixlib-shellout needs additional privileges, in other cases the user we're trying to run the process as needs them. Signed-off-by: Bryan McLellan <btm@loftninjas.org>
* Launch process with elevated tokenNimishaS2017-07-194-23/+97
| | | | Signed-off-by: NimishaS <nimisha.sharad@msystechnologies.com>
* fix chefstyle offensesLamont Granquist2017-06-203-25/+27
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* spec cleanup and some light refactoringlcg/cleanup2Lamont Granquist2017-02-013-56/+39
| | | | | | | | | | | | | | | - mostly cleans up the windows specs so its easier to read the API out of them and removes some of the very brittle internal testing - refactors the 'which' logic a bit. trying to converge towards the chef/chef version and eventually extracting common code so that do not have to maintain 10+ slightly different copies everywhere. - adds the Mixlib::ShellOut::EmptyWindowsCommand exception because letting CreateProcessW throw a generic SystemCallError is pretty much useless to everyone. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* remove largely useless Utils classLamont Granquist2017-01-271-120/+126
| | | | | | | | its just a collection of private methods, they should be private methods retain a method in the class that was being used externally. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Fix the timeout in the comment to be correctTim Smith2017-01-131-1/+1
|
* Resolve most chefstyle warningsTim Smith2016-10-074-129/+129
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>