-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathdepends_test.py
42 lines (33 loc) · 1.05 KB
/
depends_test.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/usr/bin/env python3
""" Fileorganizer: test your dependencies
----------------Authors----------------
Lachlan de Waard <[email protected]>
----------------Licence----------------
Creative Commons - Attribution Share Alike v3.0
"""
def check():
""" Importing all libraries used by FileOrganizer """
clear = False
try:
import os
import codecs
import configparser
import shutil
import subprocess
import time
import gi
import urllib.parse
gi.require_version('Peas', '1.0')
gi.require_version('PeasGtk', '1.0')
gi.require_version('Notify', '0.7')
gi.require_version('RB', '3.0')
from gi.repository import GObject, Peas, PeasGtk, Gtk, Notify, Gio
from gi.repository import RB
clear = True
except ImportError as errormsg:
print('\nDependency Problem\n\n' + str(errormsg))
if clear:
print('\nAll FileOrganizer dependencies are satisfied\n')
return True
else:
return False