mirror of
https://github.com/munki/munki.git
synced 2026-04-30 17:29:21 -05:00
Add doc string to installer.assertNoIdleSleep(); fix use of undefined 'cmd' variable.
This commit is contained in:
@@ -1067,8 +1067,10 @@ def blockingApplicationsRunning(pkginfoitem):
|
||||
|
||||
|
||||
def assertNoIdleSleep():
|
||||
"""Runs `pmset noidle` to prevent idle sleep"""
|
||||
cmd = ['/usr/bin/pmset', 'noidle']
|
||||
try:
|
||||
noIdleSleepAssertion = launchd.Job(['/usr/bin/pmset', 'noidle'])
|
||||
noIdleSleepAssertion = launchd.Job(cmd)
|
||||
noIdleSleepAssertion.start()
|
||||
except launchd.LaunchdJobException, err:
|
||||
munkicommon.display_warning(
|
||||
|
||||
Reference in New Issue
Block a user