|
|
@ -137,6 +137,9 @@ We could instead express the above using Mitogen:
|
|
|
|
|
|
|
|
|
|
|
|
::
|
|
|
|
::
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import shutil, os, subprocess
|
|
|
|
|
|
|
|
import mitogen
|
|
|
|
|
|
|
|
|
|
|
|
def run(*args):
|
|
|
|
def run(*args):
|
|
|
|
return subprocess.check_call(args)
|
|
|
|
return subprocess.check_call(args)
|
|
|
|
|
|
|
|
|
|
|
@ -144,6 +147,8 @@ We could instead express the above using Mitogen:
|
|
|
|
with open(path, 'rb') as fp:
|
|
|
|
with open(path, 'rb') as fp:
|
|
|
|
return s in fp.read()
|
|
|
|
return s in fp.read()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@mitogen.main()
|
|
|
|
|
|
|
|
def main(router):
|
|
|
|
device = '/dev/sdb1'
|
|
|
|
device = '/dev/sdb1'
|
|
|
|
mount_point = '/media/Media Volume'
|
|
|
|
mount_point = '/media/Media Volume'
|
|
|
|
|
|
|
|
|
|
|
|