Show More
@@ -1,64 +1,59 b'' | |||||
1 | # -*- coding: utf-8 -*- |
|
1 | # -*- coding: utf-8 -*- | |
2 |
|
2 | |||
3 | # Copyright (C) 2010-2020 RhodeCode GmbH |
|
3 | # Copyright (C) 2010-2020 RhodeCode GmbH | |
4 | # |
|
4 | # | |
5 | # This program is free software: you can redistribute it and/or modify |
|
5 | # This program is free software: you can redistribute it and/or modify | |
6 | # it under the terms of the GNU Affero General Public License, version 3 |
|
6 | # it under the terms of the GNU Affero General Public License, version 3 | |
7 | # (only), as published by the Free Software Foundation. |
|
7 | # (only), as published by the Free Software Foundation. | |
8 | # |
|
8 | # | |
9 | # This program is distributed in the hope that it will be useful, |
|
9 | # This program is distributed in the hope that it will be useful, | |
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | # GNU General Public License for more details. |
|
12 | # GNU General Public License for more details. | |
13 | # |
|
13 | # | |
14 | # You should have received a copy of the GNU Affero General Public License |
|
14 | # You should have received a copy of the GNU Affero General Public License | |
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
|
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
16 | # |
|
16 | # | |
17 | # This program is dual-licensed. If you wish to learn more about the |
|
17 | # This program is dual-licensed. If you wish to learn more about the | |
18 | # RhodeCode Enterprise Edition, including its added features, Support services, |
|
18 | # RhodeCode Enterprise Edition, including its added features, Support services, | |
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ |
|
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ | |
20 |
|
20 | |||
21 | import os |
|
21 | import os | |
22 | import platform |
|
|||
23 | import datetime |
|
22 | import datetime | |
24 |
|
23 | import collections | ||
25 | from collections import OrderedDict |
|
|||
26 |
|
24 | |||
27 | now = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S.%f") |
|
25 | now = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S.%f") | |
28 |
|
26 | |||
29 | print(f'{now} Starting RhodeCode imports...') |
|
27 | print(f'{now} Starting RhodeCode imports...') | |
30 |
|
28 | |||
31 | VERSION = tuple(open(os.path.join( |
|
29 | VERSION = tuple(open(os.path.join( | |
32 | os.path.dirname(__file__), 'VERSION')).read().split('.')) |
|
30 | os.path.dirname(__file__), 'VERSION')).read().split('.')) | |
33 |
|
31 | |||
34 | BACKENDS = OrderedDict() |
|
32 | BACKENDS = collections.OrderedDict() | |
35 |
|
33 | |||
36 | BACKENDS['hg'] = 'Mercurial repository' |
|
34 | BACKENDS['hg'] = 'Mercurial repository' | |
37 | BACKENDS['git'] = 'Git repository' |
|
35 | BACKENDS['git'] = 'Git repository' | |
38 | BACKENDS['svn'] = 'Subversion repository' |
|
36 | BACKENDS['svn'] = 'Subversion repository' | |
39 |
|
37 | |||
40 |
|
38 | |||
41 | CELERY_ENABLED = False |
|
39 | CELERY_ENABLED = False | |
42 | CELERY_EAGER = False |
|
40 | CELERY_EAGER = False | |
43 |
|
41 | |||
44 | # link to config for pyramid |
|
42 | # link to config for pyramid | |
45 | CONFIG = {} |
|
43 | CONFIG = {} | |
46 |
|
44 | |||
47 | # Populated with the settings dictionary from application init in |
|
45 | # Populated with the settings dictionary from application init in | |
48 | # rhodecode.conf.environment.load_pyramid_environment |
|
46 | # rhodecode.conf.environment.load_pyramid_environment | |
49 | PYRAMID_SETTINGS = {} |
|
47 | PYRAMID_SETTINGS = {} | |
50 |
|
48 | |||
51 | # Linked module for extensions |
|
49 | # Linked module for extensions | |
52 | EXTENSIONS = {} |
|
50 | EXTENSIONS = {} | |
53 |
|
51 | |||
54 | __version__ = ('.'.join((str(each) for each in VERSION[:3]))) |
|
52 | __version__ = ('.'.join((str(each) for each in VERSION[:3]))) | |
55 | __dbversion__ = 114 # defines current db version for migrations |
|
53 | __dbversion__ = 114 # defines current db version for migrations | |
56 | __platform__ = platform.system() |
|
|||
57 | __license__ = 'AGPLv3, and Commercial License' |
|
54 | __license__ = 'AGPLv3, and Commercial License' | |
58 | __author__ = 'RhodeCode GmbH' |
|
55 | __author__ = 'RhodeCode GmbH' | |
59 | __url__ = 'https://code.rhodecode.com' |
|
56 | __url__ = 'https://code.rhodecode.com' | |
60 |
|
57 | |||
61 | is_windows = __platform__ in ['Windows'] |
|
|||
62 | is_unix = not is_windows |
|
|||
63 | is_test = False |
|
58 | is_test = False | |
64 | disable_error_handler = False |
|
59 | disable_error_handler = False |
General Comments 0
You need to be logged in to leave comments.
Login now