Commit Graph

23 Commits

Author SHA1 Message Date
Greg Neagle
4053a0dbe7 Update copyright dates to 2017 2017-01-17 20:14:31 -08:00
Greg Neagle
24805bd99b Remove 'shebang' line from all Python modules that are not intended to be executed as scripts. This also causes my stupid editor to stop marking these files as executable. 2017-01-11 16:03:33 -08:00
Greg Neagle
10a6950837 Consistent if __name__ == '__main__': bit for all munkilib submodules 2016-12-24 08:17:08 -08:00
Greg Neagle
c386ede21c Move Memoize decorator to utils module 2016-12-17 09:24:15 -08:00
Greg Neagle
b126f09bb4 Move getFirstPlist function into utils 2016-12-17 09:06:40 -08:00
Wade Robson
79e8566da9 Catch OSError and IOError. Output script error 2016-04-20 08:21:48 -07:00
Wade Robson
c9f0d793df Catch unwanted OSError. Provide feedback instead. 2016-04-20 07:26:04 -07:00
Greg Neagle
12d4f0d27e Update copyright info on files; remove abandoned tools from code/tools 2016-03-15 09:32:28 -07:00
Nick McSpadden
b92285ce7d Fixed some typos 2016-03-07 18:44:40 -08:00
Samuel Keeley
5c12185da4 Replace http://www.apache.org/licenses/LICENSE-2.0 with https://www.apache.org/licenses/LICENSE-2.0 2015-11-13 20:35:24 -08:00
Greg Neagle
a3f137da33 PyLint formatting cleanup for munkilib.utils.py 2014-10-25 11:47:00 -07:00
Greg Neagle
4b71ace130 Updated copyright info on all files with copyright info. 2013-01-28 11:55:09 -08:00
Justin McWilliams
89e2ab8b81 Move getPIDforProcessName() out of munkicommon and into utils, so it can be
used in modules that munkicommon also imports.
2012-02-10 18:05:51 -05:00
Justin McWilliams
c7d2f2a9b0 Change utils.runExternalScript() script_args default from an empty list to an empty tuple.
Default arguments are evaluated once at module load time. This may cause problems if the argument is a mutable object such as a list or a dictionary. If the mutable object is changed within the function, those changes will persist to subsequent calls of the function. This wasn't a problem for runExternalScript yet, since the default arg is not changed within the function, but we might as well fix it to protect against potential future bugs.
2012-01-19 11:29:23 -05:00
Greg Neagle
833d509c94 Fix - send update notification to MSU.app after an unattended install; fix method signature for utils.runExternalScript 2011-09-14 16:43:50 -07:00
Rob Middleton
570c0f7ad4 Allow preflight/postflight to run so long as the permissions are not weaker than managedsoftwareupdate. 2011-09-14 21:31:31 +10:00
MagerValp
986a45d395 Reverting r1186, library files don't require executable bit.
git-svn-id: http://munki.googlecode.com/svn/trunk@1187 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2011-05-20 13:35:09 +00:00
MagerValp
c3fb0ff0ec Fixed missing executable bit.
git-svn-id: http://munki.googlecode.com/svn/trunk@1186 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2011-05-20 09:31:24 +00:00
Justin McWilliams
b20b212431 Fix utils.runExternalScript docstring to match change in r1092.
git-svn-id: http://munki.googlecode.com/svn/trunk@1093 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2011-04-04 21:39:42 +00:00
Justin McWilliams
3f3a3b4dfd utils.runExternalScript should return stderr, and preflight/postflight stderr should be displayed and logged if return != 0
git-svn-id: http://munki.googlecode.com/svn/trunk@1092 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2011-04-04 21:38:33 +00:00
Greg Neagle
a853f78c9f Update copyright dates across the board.
git-svn-id: http://munki.googlecode.com/svn/trunk@1010 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2011-01-25 18:22:14 +00:00
Rob Middleton
6ee6a33e96 pylint: bug in munkicommon.format_time, indentation fixes
git-svn-id: http://munki.googlecode.com/svn/trunk@931 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2010-11-27 10:10:27 +00:00
Justin McWilliams
7afec5b605 Better implementation of r863; move verifyFileOnlyWritableByMunkiAndRoot() and runExternalScript() to new munkilib utils module that is 100% free of ObjC-dependant Python.
git-svn-id: http://munki.googlecode.com/svn/trunk@865 a4e17f2e-e282-11dd-95e1-755cbddbdd66
2010-10-26 16:32:48 +00:00