mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-04-15 00:30:33 +03:00
Stub out use of watchdog module on Linux.
Fix for bug introduced by a94cf4c.
This commit is contained in:
parent
5ec1a388a9
commit
64cbffad1e
@ -90,12 +90,12 @@ Download and extract the source code of the [latest release](https://github.com/
|
||||
|
||||
Mac:
|
||||
|
||||
* Requires the Python “requests” module - install this with `easy_install requests` .
|
||||
* Requires the Python “requests” and “watchdog” modules - install these with `easy_install requests watchdog` .
|
||||
* Run with `./EDMarketConnector.py` .
|
||||
|
||||
Windows:
|
||||
|
||||
* Requires Python2.7 and the Python “requests” module.
|
||||
* Requires Python2.7 and the Python “requests” and “watchdog” modules.
|
||||
* Run with `EDMarketConnector.py` .
|
||||
|
||||
Linux:
|
||||
|
10
monitor.py
10
monitor.py
@ -8,17 +8,18 @@ from sys import platform
|
||||
from time import strptime, localtime, mktime, sleep, time
|
||||
from datetime import datetime
|
||||
|
||||
from watchdog.observers import Observer
|
||||
from watchdog.events import FileSystemEventHandler
|
||||
|
||||
if __debug__:
|
||||
from traceback import print_exc
|
||||
|
||||
if platform=='darwin':
|
||||
from AppKit import NSWorkspace
|
||||
from Foundation import NSSearchPathForDirectoriesInDomains, NSApplicationSupportDirectory, NSUserDomainMask
|
||||
from watchdog.observers import Observer
|
||||
from watchdog.events import FileSystemEventHandler
|
||||
|
||||
elif platform=='win32':
|
||||
from watchdog.observers import Observer
|
||||
from watchdog.events import FileSystemEventHandler
|
||||
import ctypes
|
||||
|
||||
CSIDL_LOCAL_APPDATA = 0x001C
|
||||
@ -63,6 +64,9 @@ elif platform=='win32':
|
||||
return False # stop enumeration
|
||||
return True
|
||||
|
||||
else:
|
||||
FileSystemEventHandler = object # dummy
|
||||
|
||||
|
||||
class EDLogs(FileSystemEventHandler):
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user