tweak filemon command
This commit is contained in:
parent
79c4bfa289
commit
b38fbdefb4
1 changed files with 6 additions and 3 deletions
|
@ -427,7 +427,7 @@ class FileMonitorCommand(Subcommand):
|
||||||
help="Uninstall (unregister) service")
|
help="Uninstall (unregister) service")
|
||||||
uninstall.set_defaults(subcommand='remove')
|
uninstall.set_defaults(subcommand='remove')
|
||||||
|
|
||||||
def run(self, args):
|
def manage_service(self, args, win32):
|
||||||
if sys.platform == 'linux2':
|
if sys.platform == 'linux2':
|
||||||
if args.subcommand == 'start':
|
if args.subcommand == 'start':
|
||||||
from edbob.filemon.linux import start_daemon
|
from edbob.filemon.linux import start_daemon
|
||||||
|
@ -437,12 +437,15 @@ class FileMonitorCommand(Subcommand):
|
||||||
stop_daemon()
|
stop_daemon()
|
||||||
|
|
||||||
elif sys.platform == 'win32':
|
elif sys.platform == 'win32':
|
||||||
from edbob.filemon.win32 import exec_server_command
|
win32.exec_server_command(args.subcommand)
|
||||||
exec_server_command(args.subcommand)
|
|
||||||
|
|
||||||
else:
|
else:
|
||||||
print "Sorry, file monitor is not supported on platform %s." % sys.platform
|
print "Sorry, file monitor is not supported on platform %s." % sys.platform
|
||||||
|
|
||||||
|
def run(self, args):
|
||||||
|
from edbob.filemon import win32
|
||||||
|
self.manage_service(args, win32)
|
||||||
|
|
||||||
|
|
||||||
class ShellCommand(Subcommand):
|
class ShellCommand(Subcommand):
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue